<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%String path = request.getContextPath();%>
<%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c" %>
<%@ taglib uri="/WEB-INF/tld/ui.tld" prefix="ui" %>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <c:set var="ctx" value="${pageContext.request.contextPath}"/>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>新增供应商</title>
    <jsp:include page="../../import.jsp" flush="true"/>
    <script type="text/javascript" src="<%=path %>/resource/lib/plugins/ajaxfileupload.js"></script>
</head>
<body class="iframeBody">
<div class="Wrapper">
    <div id="pageInTab" class="pageInTab">
        <div tabid="tabA" title="基本信息" lselected="true">
            <form id="formSet1">
                <div class="fieldset1 tabel_col clearFix">
                    <!-- 自然人供应商 -->
                    <c:if test="${splAttrCd == 1}">
                    <div class="caption">
                        <span class="title">基本信息</span>
                        <input name="splAttrCd" id="splAttrCd" type="hidden" class="ui-textbox" value="${splAttrCd }">
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">姓名</div>
                        <div class="field">
                            <input name="splNm" id="splNm" type="text" class="ui-textbox" value="${splNm }">
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">身份证号</div>
                        <div class="field">
                            <input name="bizLicNo" id="bizLicNo" type="text"
                                   class="ui-textbox" value="${bizLicNo }"
                            > <span
                                class="requiredSymbol">*</span>
                        </div>
                    </div>
                    <div class="fieldBox col_33"
                         <c:if test="${currBuOrgCd != '00000005' }">style="display: none"</c:if>>
                        <div class="label">供应商类型</div>
                        <div class="field">
                            <select name="prjLvlCd" id="prjLvlCd" data-value=" "
                                    <c:if test="${currBuOrgCd == '00000005' }">validate="{required:true,select:true}"</c:if>>
                                <option value=" " checked>请选择</option>
                                <c:forEach items="${prjLvlCdList }" var="mfr">
                                    <option value="${mfr.key }">${mfr.value }</option>
                                </c:forEach>
                            </select>
                            <c:if test="${currBuOrgCd == '00000005' }">
                                <span id="prjLvlCdSpan" class="requiredSymbol">*</span>
                            </c:if>
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">联系电话</div>
                        <div class="field">
                            <input name="splTel" id="splTel" type="text" class="ui-textbox"
                                   value="" validate="{mobileAndFixedPhone:true}">
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">通讯地址</div>
                        <div class="field" style="width: 100%;">
                            <input name="postAddr" id="postAddr" type="text"
                                   class="ui-textbox" value="">
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">邮编</div>
                        <div class="field">
                            <input name="zipNo" id="zipNo" type="text" class="ui-textbox"
                                   value="">
                        </div>
                    </div>
                    <div class="fieldBox col_66_auto">
                        <div class="label">区域</div>
                        <div class="field">
                            <jsp:include page="../../system/sysRegion/region.jsp"
                                         flush="true">
                                <jsp:param name="regionShowLvl" value="2"/>
                            </jsp:include>
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>


                    <div class="fieldBox col_33">
                        <div class="label">项目类型</div>
                        <div class="field">
                            <input name="prjTypCds" id="prjTypCds" type="text"
                                   ltype="combobox">
                        </div>
                    </div>
                    <div class="fieldBox col_33" style="display: none">
                        <div class="label">所属事业部</div>
                        <div class="field">
                            <input type="text" id="buOrgCds" name="buOrgCds" ltype="combobox"/> <span
                                class="requiredSymbol">*</span>
                        </div>
                    </div>
                    <!-- 专车新增 begin -->
                    <c:if test="${currentBuOrgCd != null and currentBuOrgCd == '00000008'}">
                        <div class="fieldBox col_33">
                            <div class="label">供应商类别（专车）</div>
                            <div class="field">
                                <select name="splTypCd" id="splTypCd" data-value="${splTypCd }">
                                    <option value="" selected="selected">请选择</option>
                                    <c:forEach items="${searchSplTypCdList}" var="stc">
                                        <option value="${stc.key}">${stc.value }</option>
                                    </c:forEach>
                                </select>
                            </div>
                        </div>
                        <div class="fieldBox col_33">
                            <div class="label">合作开始时间（专车）</div>
                            <div class="field">
                                <input type="text" id="coopDt" name="coopDt" class="ui-datepicker" value=""/>
                            </div>
                        </div>
                        <%--<div id="zk" style="display: none">--%>
                        <div class="fieldBox col_33" id="zk_01" style="display: none">
                            <div class="label">代理商协议乙方</div>
                            <div class="field">
                                <input type="text" id="agtSec" name="agtSec" value=""/>
                            </div>
                        </div>
                        <div class="fieldBox col_33" id="zk_02" style="display: none">
                            <div class="label">代理商协议丙方</div>
                            <div class="field">
                                <input type="text" id="agtThd" name="agtThd" value=""/>
                            </div>
                        </div>
                        <div class="fieldBox col_33" id="zk_03" style="display: none">
                            <div class="label">代理商基础任务量</div>
                            <div class="field">
                                <input type="text" id="bscTaskQty" name="bscTaskQty" value="" validate="{number:true}"/>
                            </div>
                        </div>
                        <div class="fieldBox col_33" id="zk_04" style="display: none">
                            <div class="label">代理商入网保证金</div>
                            <div class="field">
                                <input type="text" id="entDepAmt" name="entDepAmt" value="" validate="{number:true}"/>
                            </div>
                        </div>
                        <div class="fieldBox col_33" id="zk_05" style="display: none">
                            <div class="label">我司提供车辆最高总价值</div>
                            <div class="field">
                                <input type="text" id="prdMaxValAmt" name="prdMaxValAmt" value=""
                                       validate="{number:true}"/>
                            </div>
                        </div>
                        <%--</div>--%>
                    </c:if>
                    <!-- 专车新增 end-->
                    <div class="fieldBox col_33">
                        <div class="label">经营类型(新车)</div>
                        <div class="field">
                            <input type="text" id="newCarTyp" name="newCarTyp" ltype="combobox" validate="{required:false}"/>

                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">经营类型(二手车)</div>
                        <div class="field">
                            <input type="text" id="usedCarTyp" name="usedCarTyp" ltype="combobox" validate="{required:false}"/>
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">经销品牌(卡车类)</div>
                        <div class="field">
                            <input type="text" id="tkBrCd" name="tkBrCd" ltype="combobox"
                                   validate="{required:false}"/>
                        </div>
                    </div>
                    <!-- <div class="fieldBox col_33">
                        <div class="label">经销品牌(乘用车类)</div>
                        <div class="field">
                            <input type="text" id="carBrCd" name="carBrCd" ltype="combobox"
                                   validate="{required:false}"/>
                        </div>
                    </div> -->
                    <div class="fieldBox col_33">
                        <div class="label">经销品牌(客车类)</div>
                        <div class="field">
                            <input type="text" id="busBrCd" name="busBrCd" ltype="combobox"
                                   validate="{required:false}"/>
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">供应商所属厂商</div>
                        <div class="field">
                            <input name="mfrIds" id="mfrIds" type="text" value=""
                                   placeholder="请选择" ltype="combobox">
                        </div>
                    </div>
                    <div class="fieldBox col_33">
                        <div class="label">供应商返利比例%</div>
                        <div class="field" style="width: 100%;">
                            <input name="rebPct" id="rebPct" type="text" class="ui-textbox" value=""
                                   validate="{number:true}" disabled="disabled">
                        </div>
                    </div>
                    <!-- add by zhaoyong 20170829 begin -->
                    <%--<div class="fieldBox col_33">
                        <div class="label">是否有权查询征信</div>
                        <div class="field">
                            <input id="isAuthCrdChkYes" type="radio" value="1" name="isAuthCrdChk"/> 是
                            <input id="isAuthCrdChkNo" type="radio" value="0" name="isAuthCrdChk"/> 否
                        </div>
                    </div>--%>
                    <!-- <div class="fieldBox col_33">
                        <div class="label">每日可查询征信次数</div>
                        <div class="field" style="width: 100%;">
                            <input name="limChkTms" id="limChkTms" type="text" class="ui-textbox" value=""
                                   validate="{number:true,required:true}">
                        </div>
                    </div> -->
                    <c:if test="${isCheckVerify==1 }">
	                <div class="fieldBox col_50">
							<div class="label">三方授权书是否提供</div>
							<div class="field">
		                        <select name="isUploadLoa" id="isUploadLoa" data-value=" " validate ="{required:true,select:true}">
		                        	<option value=" " checked >请选择</option>
		                        	<option value="1">是</option>
		                        	<option value="0">否</option>
									
								</select>
		                    </div>
						</div>
						<div class="fieldBox col_50">
							<div class="label">三方授权书是否回收</div>
							<div class="field">
		                        <select name="isRecycleLoa" id="isRecycleLoa" data-value=" " validate ="{required:true,select:true}">
		                        	<option value=" " checked >请选择</option>
		                        	<option value="1">是</option>
		                        	<option value="0">否</option>
									
								</select>
		                    </div>
						</div>
						</c:if>
                    <!-- add by zhaoyong 20170829 end -->
                    <div class="fieldBox col_100">
                        <div class="label">其他信息</div>
                        <div class="field" style="width: 100%;">
									<textarea name="othInfoCd" id="othInfoCd" rows="4"
                                              class="l-textarea" style="width: 99%" value=""></textarea>
                        </div>
                    </div>
                    <c:if test="${isShowAuditBtn==1 }">
                        <div class="caption">
                            <span class="title">资料信息</span>
                        </div>
                        <div class="fieldBox col_100">
                            <div id="fileList">
                                <jsp:include page="../../system/sysUlFilesRec/sysUlFileRecListDetail.jsp" flush="true">
                                    <jsp:param name="pkId" value="${id }"/>
                                    <jsp:param name="tabNm" value="SPL_BSC_INFO"/>
                                </jsp:include>
                            </div>
                        </div>
                    </c:if>
                </div>
                </c:if>

                <!-- ======= 法人供应商 ==========-->
                <c:if test="${splAttrCd != 1}">
                <div class="caption">
                    <span class="title">基本信息</span>
                    <input name="splAttrCd" id="splAttrCd" type="hidden" class="ui-textbox" value="${splAttrCd }">
                </div>
                <div class="fieldBox col_33">
                    <div class="label">供应商名称</div>
                    <div class="field">
                        <input name="splNm" id="splNm" type="text" class="ui-textbox" value="${splNm }">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">统一社会信用代码</div>
                    <div class="field">
                        <input name="succ" id="succ" type="text" class="ui-textbox" value="${succ }" validate="{required:true}">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                    <%--<div class="fieldBox col_33">
                        <div class="label">营业执照号</div>
                        <div class="field">
                            <input name="bizLicNo" id="bizLicNo" type="text" class="ui-textbox" value="${bizLicNo }">
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>--%>
                    <%--<div class="fieldBox col_33">
                        <div class="label">税务登记号</div>
                        <div class="field">
                            <input name="taxRegNo" id="taxRegNo" type="text" class="ui-textbox" value="${bizLicNo }">
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>--%>
                    <%--<div class="fieldBox col_33">
                        <div class="label">组织机构代码号</div>
                        <div class="field">
                            <input name="orgCode" id="orgCode" type="text" class="ui-textbox" value="${bizLicNo }">
                            <span class="requiredSymbol">*</span>
                        </div>
                    </div>--%>
                <div class="fieldBox col_33" <c:if test="${currBuOrgCd != '00000005' }">style="display: none"</c:if>>
                    <div class="label">供应商类型</div>
                    <div class="field">
                        <select name="prjLvlCd" id="prjLvlCd" data-value=" "
                                <c:if test="${currBuOrgCd == '00000005' }">validate="{required:true,select:true}"</c:if>>
                            <option value=" " checked>请选择</option>
                            <c:forEach items="${prjLvlCdList }" var="mfr">
                                <option value="${mfr.key }">${mfr.value }</option>
                            </c:forEach>
                        </select>
                        <c:if test="${currBuOrgCd == '00000005' }">
                            <span id="prjLvlCdSpan" class="requiredSymbol">*</span>
                        </c:if>
                    </div>
                </div>
                <div class="fieldBox col_33" <c:if test="${currBuOrgCd != '00000001' }">style="display: none"</c:if>>
                    <div class="label">供应商级别</div>
                    <div class="field">
                        <select name="splLvlCd" id="splLvlCd" data-value=" "
                                <c:if test="${currBuOrgCd == '00000001' }">validate="{required:true,select:true}"</c:if>>
                            <option value=" " checked>请选择</option>
                            <c:forEach items="${splLvlCdList }" var="mfr">
                                <option value="${mfr.key }">${mfr.value }</option>
                            </c:forEach>
                        </select>
                        <c:if test="${currBuOrgCd == '00000001' }">
                            <span id="splLvlCdSpan" class="requiredSymbol">*</span>
                        </c:if>
                    </div>
                </div>
                <!--  <div class="fieldBox col_33">
                     <div class="label">注册电话</div>
                     <div class="field">
                         <input name="splTel" id="splTel" type="text" class="ui-textbox" value=""
                                validate="{mobileAndFixedPhone:true}">
                     </div>
                 </div> -->
                <!--  <div class="fieldBox col_33">
                     <div class="label">供应商传真</div>
                     <div class="field">
                         <input name="splFax" id="splFax" type="text" class="ui-textbox" value="">
                     </div>
                 </div> -->
                    <%-- <div class="fieldBox col_33">
                        <div class="label">企业性质</div>
                        <div class="field">
                            <select name="corpTypCd" id="corpTypCd" data-value=" ">
                                <option value=" " checked>请选择</option>
                                <c:forEach items="${corpTypCdList }" var="mfr">
                                    <option value="${mfr.key }">${mfr.value }</option>
                                </c:forEach>
                            </select>
                        </div>
                    </div> --%>
                <div class="fieldBox col_33">
                    <div class="label">成立日期</div>
                    <div class="field">
                        <input name="regDt" id="regDt" type="text" class="ui-datepicker" value="">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">有效日期</div>
                    <div class="field">
                        <input name="expDt" id="expDt" type="text" class="ui-datepicker" value="">
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">注册资本</div>
                    <div class="field">
                        <input name="regCapAmt" id="regCapAmt" type="text" class="ui-textbox" ligerui="width: 110"
                               value="" validate="{required:true,number:true}">
                        <select name="regCapUntCd" id="regCapUntCd" ligerui="width: 60" data-value="">
                            <c:forEach items="${capUntCdList }" var="kv" begin="0" step="1" varStatus="status">
                                <c:if test="${status.index == 0}">
                                    <option value="${kv.key }" checked>${kv.value }</option>
                                </c:if>
                                <c:if test="${status.index != 0}">
                                    <option value="${kv.key }">${kv.value }</option>
                                </c:if>
                            </c:forEach>
                        </select><span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">实收资本</div>
                    <div class="field">
                        <input name="paidCapAmt" id="paidCapAmt" type="text" class="ui-textbox" ligerui="width: 110"
                               value="" validate="{required:true,number:true}">
                        <select name="paidCapUntCd" id="paidCapUntCd" ligerui="width: 60" data-value="">
                            <c:forEach items="${capUntCdList }" var="kv" begin="0" step="1" varStatus="status">
                                <c:if test="${status.index == 0}">
                                    <option value="${kv.key }" checked>${kv.value }</option>
                                </c:if>
                                <c:if test="${status.index != 0}">
                                    <option value="${kv.key }">${kv.value }</option>
                                </c:if>
                            </c:forEach>
                        </select><span class="requiredSymbol">*</span>
                    </div>
                </div>
                <!-- <div class="fieldBox col_33">
                    <div class="label">是否回购</div>
                    <div class="field">
                        <input id="yesRadio" type="radio" value="1" name="isBuyBack"/> 是
                        <input id="noRadio" type="radio" value="0" name="isBuyBack"/> 否
                    </div>
                </div> -->
                <div class="fieldBox col_33">
                    <div class="label">注册地址</div>
                    <div class="field">
                        <input name="regAddr" id="regAddr" type="text" class="ui-textbox" value="" validate="{required:true}">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">公司归属</div>
                    <div class="field">
                        <select name="ownerCd" id="ownerCd" data-value=" ">
                            <option value=" " checked >请选择</option>
                            <c:forEach items="${ownerKVList }" var="owner">
                                <option value="${owner.key }">${owner.value }</option>
                            </c:forEach>
                        </select>
                    </div>
                </div>
                <div class="fieldBox col_66_auto">
                    <div class="label">区域</div>
                    <div class="field">
                        <!-- <input name="rgnPrCd" id="rgnPrCd" type="text" class="ui-textbox" value=""> -->
                        <jsp:include page="../../system/sysRegion/region.jsp" flush="true">
                            <jsp:param name="regionShowLvl" value="2"/>
                        </jsp:include>
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">供销商网址</div>
                    <div class="field">
                        <input name="websit" id="websit" type="text" class="ui-textbox" value="">
                    </div>
                </div>
                <!-- <div class="fieldBox col_33">
                    <div class="label">经营范围</div>
                    <div class="field">
                        <input name="bizScope" id="bizScope" type="text" class="ui-textbox" value="">
                    </div>
                </div> -->
                <div class="fieldBox col_33">
                    <div class="label">经营范围</div>
                    <div class="field">
                        <input type="text" id="bizScope" name="bizScope" ltype="combobox" validate="{required:false}"/>
                    </div>
                </div>

                <div class="fieldBox col_33">
                    <div class="label">办公地址</div>
                    <div class="field" style="width: 100%;">
                        <input name="postAddr" id="postAddr" type="text" class="ui-textbox" value="" validate="{required:true}">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <!-- <div class="fieldBox col_33">
                    <div class="label">企业邮编</div>
                    <div class="field" style="width: 100%;">
                        <input name="zipNo" id="zipNo" type="text" class="ui-textbox" value="">
                    </div>
                </div> -->
                <div class="caption">
                    <span class="title">更多信息</span>
                    <input name="splAttrCd" id="splAttrCd" type="hidden" class="ui-textbox" value="${splAttrCd }">
                </div>
                <div class="fieldBox col_100">
                    <div class="label">项目类型</div>
                    <div class="field">
                        <input name="prjTypCds" id="prjTypCds" type="text" ltype="combobox" validate="{required:true}">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_100" style="display: none">
                    <div class="label">所属事业部</div>
                    <div class="field">
                        <input type="text" id="buOrgCds" name="buOrgCds" ltype="combobox"/>
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <!-- 专车新增 begin -->
                <c:if test="${currentBuOrgCd != null and currentBuOrgCd == '00000008'}">
                <div class="fieldBox col_33">
                    <div class="label">供应商类别（专车）</div>
                    <div class="field">
                        <input type="text" id="splTypCd" name="splTypCd" value="请选择" ltype="combobox"/>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">合作开始时间（专车）</div>
                    <div class="field">
                        <input type="text" id="coopDt" name="coopDt" class="ui-datepicker" value=""/>
                    </div>
                </div>
                    <%--<div id="zk" style="display: none">--%>
                <div class="fieldBox col_33" id="zk_01" style="display: none">
                    <div class="label">代理商协议乙方</div>
                    <div class="field">
                        <input type="text" id="agtSec" name="agtSec" value=""/>
                    </div>
                </div>
                <div class="fieldBox col_33" id="zk_02" style="display: none">
                    <div class="label">代理商协议丙方</div>
                    <div class="field">
                        <input type="text" id="agtThd" name="agtThd" value=""/>
                    </div>
                </div>
                <div class="fieldBox col_33" id="zk_03" style="display: none">
                    <div class="label">代理商基础任务量</div>
                    <div class="field">
                        <input type="text" id="bscTaskQty" name="bscTaskQty" value="" validate="{number:true}"/>
                    </div>
                </div>
                <div class="fieldBox col_33" id="zk_04" style="display: none">
                    <div class="label">代理商入网保证金</div>
                    <div class="field">
                        <input type="text" id="entDepAmt" name="entDepAmt" value="" validate="{number:true}"/>
                    </div>
                </div>
                <div class="fieldBox col_33" id="zk_05" style="display: none">
                    <div class="label">我司提供车辆最高总价值</div>
                    <div class="field">
                        <input type="text" id="prdMaxValAmt" name="prdMaxValAmt" validate="{number:true}"/>
                    </div>
                </div>
                    <%--</div>--%>
                </c:if>
                <!-- 专车新增 end-->
                <div class="fieldBox col_33">
                    <div class="label">经营类型(新车)</div>
                    <div class="field">
                        <input type="text" id="newCarTyp" name="newCarTyp" ltype="combobox" validate="{required:false}"/>

                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">经营类型(二手车)</div>
                    <div class="field">
                        <input type="text" id="usedCarTyp" name="usedCarTyp" ltype="combobox" validate="{required:false}"/>
                        <span class="requiredSymbol">*</span>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">经销品牌(卡车类)</div>
                    <div class="field">
                        <input type="text" id="tkBrCd" name="tkBrCd" ltype="combobox" validate="{required:false}"/>
                    </div>
                </div>
                <!-- <div class="fieldBox col_33">
                    <div class="label">经销品牌(乘用车类)</div>
                    <div class="field">
                        <input type="text" id="carBrCd" name="carBrCd" ltype="combobox" validate="{required:false}"/>
                    </div>
                </div> -->
                <div class="fieldBox col_33">
                    <div class="label">经销品牌(客车类)</div>
                    <div class="field">
                        <input type="text" id="busBrCd" name="busBrCd" ltype="combobox" validate="{required:false}"/>
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">其他信息</div>
                    <div class="field" style="width: 100%;">
                        <textarea name="othInfoCd" id="othInfoCd" rows="4" class="l-textarea" style="width:99%"
                                  value=""></textarea>
                    </div>
                </div>
                <c:if test="${isCheckVerify==1 }">
                <div class="fieldBox col_50">
						<div class="label">三方授权书是否提供</div>
						<div class="field">
	                        <select name="isUploadLoa" id="isUploadLoa" data-value=" " validate ="{required:true,select:true}">
	                        	<option value=" " checked >请选择</option>
	                        	<option value="1">是</option>
	                        	<option value="0">否</option>
								
							</select>
	                    </div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">三方授权书是否回收</div>
						<div class="field">
	                        <select name="isRecycleLoa" id="isRecycleLoa" data-value=" " validate ="{required:true,select:true}">
	                        	<option value=" " checked >请选择</option>
	                        	<option value="1">是</option>
	                        	<option value="0">否</option>
								
							</select>
	                    </div>
					</div>
					</c:if>
                <div class="fieldBox col_100_auto">
                    <div class="label">供应商所属厂商</div>
                    <div class="field">
                        <input name="mfrIds" id="mfrIds" type="text" value="" placeholder="请选择" ltype="combobox">
                    </div>
                </div>
                <div class="fieldBox col_33">
                    <div class="label">供应商返利比例%</div>
                    <div class="field" style="width: 100%;">
                        <input name="rebPct" id="rebPct" type="text" class="ui-textbox" value=""
                               validate="{number:true}" disabled="disabled">
                    </div>
                </div>
                <!-- add by zhaoyong 20170829 begin -->
                <!--  <div class="fieldBox col_33">
                     <div class="label">是否有权查询征信</div>
                     <div class="field">
                         <input id="isAuthCrdChkYes" type="radio" value="1" name="isAuthCrdChk"/> 是
                         <input id="isAuthCrdChkNo" type="radio" value="0" name="isAuthCrdChk"/> 否
                     </div>
                 </div> -->
                <!-- <div class="fieldBox col_33">
                    <div class="label">每日可查询征信次数</div>
                    <div class="field" style="width: 100%;">
                        <input name="limChkTms" id="limChkTms" type="text" class="ui-textbox" value=""
                               validate="{number:true,required:true}">
                        <span class="requiredSymbol">*</span>
                    </div>
                </div> -->
        </div>
        <div class="sqPanel">
            <div class="sqPanel_head inL">
                <c:if test="${audStsCd!=1 }">
                    <div class="btnsBox inLC">
                        <span id="spl_rl_add_btn" class="sq-button sq-button-round"
                              onclick="splRlAddBtnEvent();">添加</span>
                    </div>
                </c:if>
                <span>主要人员信息</span>
            </div>
            <div class="sqPanel_body">
                <div id="ligergrid_A1" class="sq-grid"></div>
            </div>
        </div>
        <%--//修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13--%>

    <%--<c:if test="${currBuOrgCd=='00000001' ||  currBuOrgCd=='0000'}">
            <div class="sqPanel">
                <div class="fieldset1 tabel_col clearFix">
                    <div class="sqPanel_head inL">
                        <span>流程权限信息</span>
                    </div>
                    <div class="sqPanel_body">
                        <div class="fieldBox col_100">
                            <div class="label">可支持流程</div>
                            <div class="field">
                                <div class="allCheckBox">
                                    <input id="ALL" type="checkbox" value="ALL" name="ALL"
                                    <c:if test="${audStsCd==1 }"> disabled="true"</c:if>
                                           onchange="allChange();"><span>全选</span><br/>
                                    <c:forEach items="${kvList }" var="kv" begin="0" step="1" varStatus="status">
                                        <input id="${kv.key }" type="checkbox" value="${kv.key }" name="pDefKey"
                                               onchange="pDefKeyChange();">
                                        <span>${kv.value }
                                    <c:if test="${kv.key=='FLOW_00000001_007_001' }">
                                        <span id="f_${kv.key }" style="display: none">
                                            <span style="color: red;">支持不上牌资产数量</span>
                                            <input name="flowNum${kv.key }" id="flowNum${kv.key }" type="text" value=""
                                                   style="width: 50px">台
                                            <span style="color: red;">超期30天未上牌车辆数量</span>
					                        <input name="expire${kv.key }" id="expire${kv.key }" type="text" value="" style="width: 50px"
                                                   <c:if test="${saveNoSpNum!=1 }">readonly="readonly"</c:if>>台
                                        </span>
                                    </c:if>

                                    <c:if test="${kv.key == 'FLOW_00000001_035_001'}">
                                         <span id="f_${kv.key }" style="display: none">
                                            <span style="color: red;">支持不上牌资产数量</span>
                                            <input name="flowNum${kv.key }" id="flowNum${kv.key }" onblur="fonselblur();" type="text" value=""
                                                   style="width: 50px">台
                                            <input id="flowNumcheckb" type="checkbox" onchange="onsetNumVal();" value="" name="flowNumcheckb" /> 不限制
                                        </span>
                                    </c:if>
			    		        </span>
                                        <br/>
                                    </c:forEach>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="sqPanel_body">
                        <div class="fieldBox col_100">
                            <div class="label">备注说明</div>
                            <div class="field">
                            <textarea name="flowRem" id="flowRem" rows="4" class="l-textarea" style="width:99%"
                                      value=""></textarea>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </c:if>--%>
        <c:if test="${not empty isApply}">
            <div class="splBizFlowPanel">
                <div class="fieldset1 tabel_col clearFix">
                    <div class="sqPanel">
                        <div class="sqPanel_head inL">
                            <span>变更资料信息</span>
                            <span class="btns"><span class="sq-button sq-button-round" onclick="downloadSplFileByUrl();">打包下载</span></span>
                        </div>
                        <div class="sqPanel_body">
                            <div id="splFileInfoCfgGrid" class="sq-grid"></div>
                        </div>
                    </div>

                        <%--<div class="caption">
                            <span class="title">资料信息</span>
                        </div>
                        <c:if test="${audStsCd==1 }">
                            <div class="fieldBox col_100">
                                <div id="fileList">
                                    <jsp:include page="../../system/sysUlFilesRec/sysUlFileRecListDetail.jsp" flush="true">
                                        <jsp:param name="pkId" value="${applyId }"/>
                                        <jsp:param name="tabNm" value="SPL_BSC_INFO_APPLY"/>
                                        <jsp:param name="isShowAudStsCd" value="1"/>
                                    </jsp:include>
                                </div>
                            </div>
                        </c:if>
                        <c:if test="${audStsCd!=1 }">
                            <div class="fieldBox col_100">
                                <div id="fileList">
                                    <jsp:include page="../../system/sysUlFilesRec/sysUlFileRecList.jsp" flush="true">
                                        <jsp:param name="pkId" value="${applyId }"/>
                                        <jsp:param name="tabNm" value="SPL_BSC_INFO_APPLY"/>
                                        <jsp:param name="isShowAudStsCd" value="1"/>
                                    </jsp:include>
                                </div>
                            </div>
                            <div class="caption">
                                <span class="title">资料上传</span>
                            </div>
                            <div class="fieldBox col_100">
                                <div id="fileUpload">
                                    <jsp:include page="../../system/sysUlFilesRec/sysSysUlFilesRecUpload2.jsp" flush="true">
                                        <jsp:param name="filePath" value="/splbscApplyFlow"/>
                                    </jsp:include>
                                </div>
                            </div>
                        </c:if>--%>
                </div>
            </div>
        </c:if>

        </c:if>
        <div class="btnsBox">
            <c:if test="${audStsCd!=1 }">
                <span id="saveBtn1" onclick="wsCheck()" class="sq-button sq-button-round">保存</span>
            </c:if>
            <c:if test="${audStsCd == 1 }">
                <span id="relationships" onclick="relationshipsView()" class="sq-button sq-button-round">集团关联图谱</span>
                <span id="saveBtn1" onclick="wsCheck()" class="sq-button sq-button-round">保存</span>
            </c:if>
            <input name="sId" id="sId" type="hidden" value="${id }">
            <input name="applyId" id="applyId" type="hidden" value="${applyId }">
            <input name="audStsCd" id="audStsCd" type="hidden" value="${audStsCd }">
            <input name="auditStatus" id="auditStatus" type="hidden" value="${auditStatus }">
            <input name="qualTypCd" id="qualTypCd" type="hidden" value="${qualTypCd }">
        </div>
        </form>
    </div>
    <div tabid="tabB" title="备案资料">
        <iframe frameborder="0" name="tabB" id="tabB" src=""></iframe>
    </div>
    <div tabid="tabD" title="备案账号">
        <iframe frameborder="0" name="tabD" id="tabD" src=""></iframe>
    </div>
    <div tabid="tabE" title="相关项目">
        <iframe frameborder="0" name="tabE" id="tabE" src=""></iframe>
    </div>
    <div tabid="tabG" title="配置维护">
        <iframe frameborder="0" name="tabG" id="tabG" src=""></iframe>
    </div>
    <div tabid="tabH" title="变更记录">
        <iframe frameborder="0" name="tabH" id="tabH" src=""></iframe>
    </div>
    <div tabid="tabJ" title="人工干预">
        <iframe frameborder="0" name="tabJ" id="tabJ" src=""></iframe>
    </div>
</div>

<!-- 操作原因 -->
<form id="reasonFromSet" style="display:none;">
    <div class="field">
        <textarea name="reason" id="reason" class="ui-textarea l-textarea" style="width:360px;height: 150px;" validate="{required:true}" ></textarea>
    </div>
</form>


<script type="text/javascript">
    var extData = null;
    var npSocialRlGrid;//联系人GRID
    var _brJson = [];
    var loadedTabs = [];
    var lxxz = '${lxxz}';
    var prdmarks = '${prdmarks}';

    var proIntId = '${proIntId}';
    var oldAgtSec = "";
    var oldAgtThd = "";
    var oldBscTaskQty = "";
    var oldEntDepAmt = "";
    var oldPrdMaxValAmt = "";
    var audStsCd = '${audStsCd}';
    var auditStatus = '${auditStatus}';
    var splAttrCd = '${splAttrCd}';
    var qualTypCd = '${qualTypCd}';
    var applyId = '${applyId}';

    var _cfgSysCd = '${cfgSysCd}'; //附件系统CODE
    var _cfgOrgCd = '${cfgOrgCd}'; //附件组织架构
    var _tabNm = '${tabNm}'; //附件对应表
    var _cfgCd = '${cfgCd}'; //附件CODE
    var _modulePath = '${modulePath}';
    var _costomerPath = '${costomerPath}';
    var _rootPath = '${rootPath}';
    var _uploadSysCd = '${uploadSysCd}';
    var _isApply = '${isApply}';
    var isCheckVerify = '${isCheckVerify}';

    var splFileInfoCfgGrid = null;//经销商资料配置明细

    var upload_result_params = [];
    var serverPrefixPath = "";
    
    var flowNode = '${flowNode}';
    
    var flowType = '${flowType}'//变更流程类型，1：工商变更，0：基础变更  控制页面可修改字段

    $(function () {
        //获取服务器路径前缀
        $.ajax({
            type: 'get',
            url: '<%=path%>/system/sysulfilesrec/getServerPath.do',
            success:function(msg){
                serverPrefixPath = msg;
                console.log(serverPrefixPath);
            }
        });

        var _tkBrCdListJSON = ${tkBrCdListJSON};
        $("#tkBrCd").ligerComboBox({
            isShowCheckBox: true, isMultiSelect: true,
            data: _tkBrCdListJSON,
            valueField: 'key',
            textField: 'value'
        });
        var _carBrCdListJSON = ${carBrCdListJSON};
        $("#carBrCd").ligerComboBox({
            isShowCheckBox: true, isMultiSelect: true,
            data: _carBrCdListJSON,
            valueField: 'key',
            textField: 'value'
        });
        var _newCarTypJSON = ${newCarTypJSON};
        $("#newCarTyp").ligerComboBox({ isShowCheckBox: true, isMultiSelect: true,
            data: _newCarTypJSON,
            valueField: 'key',
            textField:'value'
        });
        var _usedCarTypJSON = ${usedCarTypJSON};
        $("#usedCarTyp").ligerComboBox({ isShowCheckBox: true, isMultiSelect: true,
            data: _usedCarTypJSON,
            valueField: 'key',
            textField:'value'
        });
        var _bizScopeTypJSON = ${bizScopeTypJSON};
        $("#bizScope").ligerComboBox({ isShowCheckBox: true, isMultiSelect: true,
            data: _bizScopeTypJSON,
            valueField: 'key',
            textField:'value'
        });
        var _busBrCdListJSON = ${busBrCdListJSON};
        $("#busBrCd").ligerComboBox({
            isShowCheckBox: true, isMultiSelect: true,
            data: _busBrCdListJSON,
            valueField: 'key',
            textField: 'value'
        });
        //项目类型
        var _prjTypCdsJson = ${prjTypCdsJson};
        $("#prjTypCds").ligerComboBox({
            isShowCheckBox: true, isMultiSelect: true,
            data: _prjTypCdsJson,
            valueField: 'key',
            textField: 'value',
        });
        // 专车事业部 供应商类别
        var _searchSplTypCdList = ${searchSplTypCdList};
        $("#splTypCd").ligerComboBox({
            isShowCheckBox: true,
            isMultiSelect: false,
            data: _searchSplTypCdList,
            valueField: 'key',
            textField: 'value',
            onChangeValue: function (value) {
                var _splTypCd = liger.get("splTypCd");
                var splTypCd = _splTypCd.getValue();
                if (splTypCd != null && splTypCd.toString().indexOf('1') > -1) {
                    $("#agtSec").val(oldAgtSec);
                    $("#agtThd").val(oldAgtThd);
                    $("#bscTaskQty").val(oldBscTaskQty);
                    $("#entDepAmt").val(oldEntDepAmt);
                    $("#prdMaxValAmt").val(oldPrdMaxValAmt);
                } else {
                    $("#agtSec").val("");
                    $("#agtThd").val("");
                    $("#bscTaskQty").val("");
                    $("#entDepAmt").val("");
                    $("#prdMaxValAmt").val("");
                }
            }
        });
        //事业部
        var _buOrgCdsJson = ${buOrgCdsJson};
        $("#buOrgCds").ligerComboBox({
            isShowCheckBox: true, isMultiSelect: true,
            data: _buOrgCdsJson,
            valueField: 'key',
            textField: 'value',
            onChangeValue: function (value) {
                var _buOrg = liger.get("buOrgCds");
                var _buOrgCds = _buOrg.getValue();
            }
        });

        $('#reasonFromSet').ligerForm({
            validate : true
        });

        var formSet1 = $('#formSet1').ligerForm({
            validate: true
        });
        formSet1.setFieldValidate("rgnProvCd", {
            required: true,
            select: false
        });
        formSet1.setFieldValidate("rgnCityCd", {
            required: true,
            select: false
        });
        var _mfrId = '${mfrId}';
        if (_mfrId != "") {
            comboGrid_defaultValue = _mfrId;
        }
        var _buOrgCd = '${buOrgCd}';
        var id = $("#sId").val();
        if (!id) {
            if (_buOrgCd != "") {
                $("#buOrgCds").ligerGetComboBoxManager().selectValue(_buOrgCd);
                $("#buOrgCds").ligerGetComboBoxManager().updateStyle();
            }
        }
		if(flowType == 1){
			disableFiledByFlowType();
		}
        initTab();
        initData();
        initSplRlGrid();
        //修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13

        /*if (currBuOrgCd == '00000001' ||currBuOrgCd == '0000'  ) {
            initFlowData();
        }*/
        //资料信息 add by jiangzg 2018-12-14 11:34:38
        splFileInfoCfgGrid = $("#splFileInfoCfgGrid").ligerGrid({
            url: '<%=path%>/product/splApplyInfo/initSplApplyFileInfoList.do?applyId='+applyId+'&cfgCd='+_cfgCd +'&tabNm='+_tabNm +"&cfgSysCd="+_cfgSysCd+'&cfgOrgCd='+_cfgOrgCd+'&uploadSysCd='+_uploadSysCd,
            method: 'get',
            columns: [
                {display: '资料名称', name: 'datNm',align: 'left', minWidth: 100, enabledSort: false},
                {display: '上传文件名称', name: 'fileNm',align: 'left', minWidth: 100, enabledSort: false,
                    render:function(rowdata,rowindex,value){
                        if(value){
                            var h;
                            h='<a href="javascript:uploadFileByUrl(';
                            h+="'"+rowdata.filePath+"'";
                            h+=",'"+rowdata.fileNm+"'";
                            h+=')">'+rowdata.fileNm+'</a>'
                            return h;
                        }
                    }
                },
                {display: '上传文件路径', name: 'filePath',align: 'left', minWidth: 100,hide:true},
                {display: '上传文件明细', name: 'cfgDtlCd',align: 'left', minWidth: 100,hide:true},
                {display: '上传时间', name: 'crtTm',align: 'left', minWidth: 100, enabledSort: false,render:renderDate},
                {display: '状态', name: 'audStsCdNm', width: 100, enabledSort: false},
                {display: '操作', name: '', minWidth: 200,align: 'left',  enabledSort: false,
                    render:function(rowdata,rowindex,value){
                        var h='';
                        if(rowdata.audStsCd){
                            if(rowdata.audStsCd !=1){
                                if(!isCheckVerify || isCheckVerify != 1 ){
                                    if(rowdata.fileId) {
                                        h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="delFile(event,' + rowdata.fileId + ');"><i class="sqBtnIco_7"></i>删除</a>';
                                    }else{
                                        h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="delUpLoadindFile(event,' + rowindex +','+rowdata.cfgDtlCd+');"><i class="sqBtnIco_7"></i>删除</a>';
                                    }
                                }else{
                                    h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="modifyAudStsCd(event,' + rowdata.fileId + ',1);"><i class="sqBtnIco_15"></i>验证通过</a>';
                                    h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="modifyAudStsCd(event,' + rowdata.fileId + ',2);"><i class="sqBtnIco_14"></i>验证不通过</a>';
                                }
                            }else{
                                h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="modifyAudStsCd(event,' + rowdata.fileId + ',1);"><i class="sqBtnIco_15"></i>验证通过</a>';
                                h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="modifyAudStsCd(event,' + rowdata.fileId + ',2);"><i class="sqBtnIco_14"></i>验证不通过</a>';
                            }
                        }else{
                            h += '<a class="sq-button-hasicon" style="cursor:pointer;" onclick="delUpLoadindFile(event,' + rowindex + ','+rowdata.cfgDtlCd+');"><i class="sqBtnIco_7"></i>删除</a>';
                        }
                        return h;
                    }
                },
                {display: '上传', name: 'uploadNm', width: 80,align: 'left', enabledSort: false,
                    render:function(rowdata,rowindex,value){
                        var h='';
                        if(audStsCd && audStsCd != 1){
                            if(rowdata.fileId){
                                if(rowdata.audStsCd && rowdata.audStsCd !=1){
                                    h+='<span class="sq-button sq-button-round fileupload-button">上传<input type="file" id="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'" multiple name="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'"' +
                                        ' class="fileupload-input" onchange="onChangefile_multi(event,\''+rowdata.cfgCd+'\',\''+rowdata.cfgDtlCd+'\',\''+rowdata.orgCd+'\',\''+rowdata.fileId+'\',\''+rowindex+'\')"></span>';
                                }else if(!rowdata.audStsCd){
                                    h+='<span class="sq-button sq-button-round fileupload-button">上传<input type="file" id="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'" multiple name="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'"' +
                                        ' class="fileupload-input" onchange="onChangefile_multi(event,\''+rowdata.cfgCd+'\',\''+rowdata.cfgDtlCd+'\',\''+rowdata.orgCd+'\',\''+rowdata.fileId+'\',\''+rowindex+'\')"></span>';
                                }
                            }else{
                                h+='<span class="sq-button sq-button-round fileupload-button">上传<input type="file" id="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'" multiple name="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'"' +
                                    ' class="fileupload-input" onchange="onChangefile_multi(event,\''+rowdata.cfgCd+'\',\''+rowdata.cfgDtlCd+'\',\''+rowdata.orgCd+'\',\''+rowdata.fileId+'\',\''+rowindex+'\')"></span>';
                            }
                        }

                        /*if(!rowdata.fileId || (!rowdata.audStsCd || rowdata.audStsCd !=1) || (audStsCd && audStsCd !=1)){
                            h+='<span class="sq-button sq-button-round fileupload-button">上传<input type="file" id="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'" multiple name="fileup_'+rowdata.cfgCd+'_'+rowdata.cfgDtlCd+'"' +
                                ' class="fileupload-input" onchange="onChangefile_multi(event,\''+rowdata.cfgCd+'\',\''+rowdata.cfgDtlCd+'\',\''+rowdata.orgCd+'\',\''+rowdata.fileId+'\',\''+rowindex+'\')"></span>';
                        }*/
                        return h;
                    }
                },
            ],
            root: 'rows',
            hideLoadButton : true,
            width: '100%',
            height: '100%',
            isScroll: false,
            rownumbers:true,  //显示序号
            checkbox: false,
            allowUnSelectRow:true,
            alternatingRow: false,
            frozen: false,
            usePager: false,
            onAfterShowData: function ()
            {
                $('#splFileInfoCfgGrid').rowspan('datNm');
                $('#splFileInfoCfgGrid').rowspan('uploadNm');
            },
        });
        disableFiled();
    });
    function disableFiledByFlowType() {
            if (liger.get("splNm")) {
                liger.get("splNm").setDisabled(true);
            }
            if (liger.get("succ")) {
                liger.get("succ").setDisabled(true);
            }
            if (liger.get("bizLicNo")) {
                liger.get("bizLicNo").setDisabled(true);
            }
            if (liger.get("taxRegNo")) {
                liger.get("taxRegNo").setDisabled(true);
            }
            if (liger.get("orgCode")) {
                liger.get("orgCode").setDisabled(true);
            }
            //非汽车金融  供应商类型禁止
            if (currBuOrgCd != '00000005') {
                if (liger.get("prjLvlCd")) {
                    liger.get("prjLvlCd").setDisabled(true);
                }
            }
            //非重卡  供应商级别禁止
            if (currBuOrgCd != '00000001') {
                if (liger.get("splLvlCd")) {
                    liger.get("splLvlCd").setDisabled(true);
                }
            }
            if (liger.get("splTel")) {
                liger.get("splTel").setDisabled(true);
            }
            if (liger.get("splFax")) {
                liger.get("splFax").setDisabled(true);
            }
            if (liger.get("corpTypCd")) {
                liger.get("corpTypCd").setDisabled(true);
            }
            if (liger.get("regDt")) {
                liger.get("regDt").setDisabled(true);
            }
            if (liger.get("expDt")) {
                liger.get("expDt").setDisabled(true);
            }
            if (liger.get("regCapAmt")) {
                liger.get("regCapAmt").setDisabled(true);
            }
            if (liger.get("regCapUntCd")) {
                liger.get("regCapUntCd").setDisabled(true);
            }
            if (liger.get("paidCapAmt")) {
                liger.get("paidCapAmt").setDisabled(true);
            }
            if (liger.get("paidCapUntCd")) {
                liger.get("paidCapUntCd").setDisabled(true);
            }
            if(liger.get("ownerCd")){
                liger.get("ownerCd").setDisabled(true);
            }
            if (liger.get("regAddr")) {
                liger.get("regAddr").setDisabled(true);
            }
            //禁用省市
            disabledRgnProvCd();
            disabledRgnCityCd();
            if (liger.get("websit")) {
                liger.get("websit").setDisabled(true);
            }
            if (liger.get("bizScope")) {
                liger.get("bizScope").setDisabled(true);
            }
            if (liger.get("fileNo")) {
                liger.get("fileNo").setDisabled(true);
            }
            if (liger.get("postAddr")) {
                liger.get("postAddr").setDisabled(true);
            }
            if (liger.get("zipNo")) {
                liger.get("zipNo").setDisabled(true);
            }
            if (liger.get("prjTypCds")) {
                liger.get("prjTypCds").setReadonly(true);
            }
            if (liger.get("tkBrCd")) {
                liger.get("tkBrCd").setReadonly(true);
            }
            if (liger.get("carBrCd")) {
                liger.get("carBrCd").setReadonly(true);
            }
            if (liger.get("busBrCd")) {
                liger.get("busBrCd").setReadonly(true);
            }
            if(liger.get("newCarTyp")){
                liger.get("newCarTyp").setDisabled(true);
            }
            if(liger.get("usedCarTyp")){
                liger.get("usedCarTyp").setDisabled(true);
            }
            $("#othInfoCd").setDisabled_ligerTextarea(true);
            if (liger.get("mfrIds")) {
                liger.get("mfrIds").setReadonly(true);
            }
            if (liger.get("rebPct")) {
                liger.get("rebPct").setDisabled(true);
            }
            /*  liger.get("limChkTms").setDisabled(true); */
            $("#flowRem").setDisabled_ligerTextarea(true);
            if (liger.get("splLvlCd")) {
                liger.get("splLvlCd").setDisabled(true);
            }
    }
    //删除文件
    function delFile(event,_fileId){
        top.$.ligerDialog.confirm("确认删除吗?", function (flag) {
            if(!flag){
                return;
            }else{
                var wait_dialog;
                $.ajax({
                    type: 'post',
                    dataType: 'json',
                    data: {'fileId':_fileId},
                    url: '<%=path%>/product/splInfo/removeFile.do',
                    beforeSend: function () {
                        wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
                    },
                    success: function (msg) {
                        wait_dialog.close();
                        if (msg.success == 1) {
                            $.ligerDialog.SQalert({content: msg.info, SQ_type: "success"});
                            event.stopPropagation();

                            refreshUlFileRecList();//刷新文件列表
                            clearUploadResultParams();//清除上传结果参数

                            var gridID = $(event.target).parents('.sq-grid').attr('ligeruiid');
                            liger.get(gridID).reload();

                        }else{
                            $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                        }
                    }
                });
            }
        });
    }

    function onChangefile_multi(e,cfgCd,cfgDtlCd,orgCd,fileId,rowIndex) {
        console.log("e == " + JSON.stringify(e) +",rowIndex==" + rowIndex);
        var wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
        var filePath= _modulePath; //之前无 '/'
        console.log("filePath ==="+filePath);
        $.ajaxFileUpload({
            url: '<%=path%>/system/sysulfilesrec/upload.do',
            secureuri: false,
            fileElementId: e.target.id,  //这里不在是以前的id了，要写成数组的形式！
            dataType: 'json',
            data: {filePath: filePath,costomerPath:_costomerPath,rootPath:_rootPath,uploadSysCd:_uploadSysCd},
            success: function (msg) {
                if (msg.success == 1) {
                    if(serverPrefixPath.length >1 && serverPrefixPath.indexOf("\"")>=0){
                        serverPrefixPath = serverPrefixPath.substring(1,serverPrefixPath.length-1);
                    }
                    var uploadJOSN = JSON.parse(JSON.stringify(msg.data));
                    console.log("uploadJOSN =s= " + JSON.stringify(uploadJOSN));
                    for (var i=0; i< uploadJOSN.length; i++){
                        var oldPath = "";
                        var newPath = "";
                        oldPath = uploadJOSN[i].filePath;
                        newPath = serverPrefixPath + oldPath;
                        //uploadJOSN[i].filePath = newPath;
                        splFileInfoCfgGrid.updateCell("filePath",oldPath,rowIndex);
                        splFileInfoCfgGrid.updateCell("fileNm",uploadJOSN[i].fileNm,rowIndex);
                        splFileInfoCfgGrid.updateCell("cfgDtlCd",cfgDtlCd,rowIndex);
                        splFileInfoCfgGrid.updateCell("crtTm",new Date(),rowIndex);
                        uploadJOSN[i].cfgCd = cfgCd ;
                        uploadJOSN[i].cfgDtlCd = cfgDtlCd;
                        uploadJOSN[i].orgCd = orgCd;
                        uploadJOSN[i].tabNm = _tabNm;
                        uploadJOSN[i].sysCd = _cfgSysCd;
                        upload_result_params.push(uploadJOSN[i]);
                        console.log("upload_result_params =s= " + JSON.stringify(upload_result_params));
                    }
                    wait_dialog.close();
                } else {
                    wait_dialog.close();
                    $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                }
            }
        });
    };

    //删除文件
    function delUpLoadindFile(event,rowIndex,cfgDtlCd){
        top.$.ligerDialog.confirm("确认删除吗?", function (flag) {
            if(!flag){
                return;
            }else{
                var wait_dialog;
                wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
                for (var i=0; i< upload_result_params.length; i++){
                    if(upload_result_params[i].cfgDtlCd == cfgDtlCd){
                        console.log("cfgDtlCd =j= " + cfgDtlCd);
                        upload_result_params.splice(i,1);
                        break;
                    }
                }
                splFileInfoCfgGrid.updateCell("filePath",'',rowIndex);
                splFileInfoCfgGrid.updateCell("fileNm",'',rowIndex);
                splFileInfoCfgGrid.updateCell("crtTm",'',rowIndex);
                console.log("upload_result_params =k= " + JSON.stringify(upload_result_params));
                wait_dialog.close();
            }
        });
    }

    //修改资料的验证状态
    function modifyAudStsCd(event,_fileId,_audStsCd){
        var wait_dialog;
        $.ajax({
            type: 'post',
            dataType: 'json',
            data: {'fileId':_fileId,'audStsCd':_audStsCd},
            url: '<%=path%>/product/splInfo/modifyFileAudStsCd.do',
            beforeSend: function () {
                wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
            },
            success: function (msg) {
                wait_dialog.close();
                if (msg.success == 1) {
                    //$.ligerDialog.SQalert({content: msg.info, SQ_type: "success"});
                    event.stopPropagation();
                    var gridID = $(event.target).parents('.sq-grid').attr('ligeruiid');
                    liger.get(gridID).reload();
                }else{
                    $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                }
            }
        });
    }

    function downloadSplFileByUrl() {
        var data = splFileInfoCfgGrid.getData();
        //var files = [];
        var ids = [];
        for (var i = 0; i < data.length; i++) {
            var map = {};
            if(StringUtils.isNotEmpty(data[i].fileId)){
                ids.push(data[i].fileId);
            }
        }
        var actoinURL = '<%=path%>/system/sysulfilesrec/zipDownloadById.do?';
        var form = $("<form>");
        $('body').append(form);
        form.attr('style','display:none');
        form.attr('target','');
        form.attr('method','post');
        form.attr('action',actoinURL);//下载文件的请求路径
        var input = $('<input>');
        input.attr('type','hidden');
        input.attr('name','ids');
        input.attr('value',JSON.stringify(ids));
        form.append(input);
        form.submit();
    }

    //格式化时间
    function renderDate(rowdata, index, value) {
        var dateStr = "";
        if (null != value && ''!= value) {
            var date = new Date(value);
            dateStr = DateUtils.formatDate(date, DateUtils.YYYY_MM_DDHHMMSS);
        }
        return dateStr;
    }

    var currBuOrgCd = '${currBuOrgCd}';

    /**
     * 数据加载
     */
    function initData() {
        var id = $("#sId").val();
        var applyId = $("#applyId").val();
        $("#rebPct").val(100);
        if (!id) {
            return;
        }
        var _url = '<%=path%>/product/splApplyInfo/initSplApplyById.do';
        $.ajax({
            type: 'get',
            dataType: 'json',
            data: {id: id, applyId: applyId},
            url: _url,
            success: function (msg) {
                if (msg.success == 1) {
                    extData = msg.data;
                    setData(msg.data);//设置数据
                } else {
                    $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                }
            }
        });
    }

    //设置页面数据
    function setData(data) {
        var form = liger.get("formSet1");
        form.setData({
            corpTypCd: data.corpTypCd,
            ownerCd: data.ownerCd,
            splLvlCd: data.splLvlCd,
            isUploadLoa:data.isUploadLoa,
            isRecycleLoa:data.isRecycleLoa,
            prjLvlCd:data.prjLvlCd
        });
        //是否可以查询征信
        $("input[name='isAuthCrdChk'][value=" + data.isAuthCrdChk + "]").prev(".l-radio").click();
        $("#limChkTms").val(data.limChkTms);
        //add by zhaoyong 20170829   end
        //区域数据处理
        setRgnProvCdUpdataValue(data.rgnPrCd);
        setRgnCityCdUpdataValue(data.rgnCyCd);
        setRegionSelectDataChange();

        $("#succ").val(data.succ);
        $("#splNm").val(data.splNm);
        $("#taxRegNo").val(data.taxRegNo);
        $("#splTel").val(data.splTel);
        $("#splFax").val(data.splFax);
        $("#bizLicNo").val(data.bizLicNo);
        $("#flowRem").val(data.flowRem);
        $("#orgCode").val(data.orgCode);
        $("#regCapAmt").val(data.regCapAmt);
        $("#regCapUntCd").val(data.regCapUntCd);
        $("#paidCapAmt").val(data.paidCapAmt);
        $("#paidCapUntCd").val(data.paidCapUntCd);
        $("#ownerCd").val(data.ownerCd);
        $("#isUploadLoa").val(data.isUploadLoa);
        $("#isRecycleLoa").val(data.isRecycleLoa);
        $("#regAddr").val(data.regAddr);
        $("#postAddr").val(data.postAddr);
        $("#websit").val(data.websit);
        $("#bizScope").val(data.bizScopeCdStr);
        $("#othInfoCd").val(data.othInfoCd);
        $("#zipNo").val(data.zipNo);
        if (data == null || data.rebPct == 0 || data.rebPct == '' || data.rebPct == '0' || data.rebPct == null) {
            $("#rebPct").val(100);
        } else {
            $("#rebPct").val(data.rebPct);
        }
        //日期处理
        if (data.regDt) {
            var date = new Date(data.regDt);
            var dateStr = DateUtils.formatDate(date, DateUtils.YYYY_MM_DD);
            $("#regDt").val(dateStr);
        }
        if (data.expDt) {
            var date = new Date(data.expDt);
            var dateStr = DateUtils.formatDate(date, DateUtils.YYYY_MM_DD);
            $("#expDt").val(dateStr);
        }
        //所属事业部 处理
        var buOrgCdsString = data.buOrgCdsString;
        $("#buOrgCds").ligerGetComboBoxManager().selectValue(buOrgCdsString);
        $("#buOrgCds").ligerGetComboBoxManager().updateStyle();
        //品牌处理
        var tkBrCdsString = data.tkBrCdsString;
        $("#tkBrCd").ligerGetComboBoxManager().selectValue(tkBrCdsString);
        $("#tkBrCd").ligerGetComboBoxManager().updateStyle();
        /*  var carBrCdsString = data.carBrCdsString;
         $("#carBrCd").ligerGetComboBoxManager().selectValue(carBrCdsString);
         $("#carBrCd").ligerGetComboBoxManager().updateStyle(); */
        var busBrCdsString = data.busBrCdsString;
        $("#busBrCd").ligerGetComboBoxManager().selectValue(busBrCdsString);
        $("#busBrCd").ligerGetComboBoxManager().updateStyle();
        //经营范围
        var newCarTypString  = data.newCarString;
        $("#newCarTyp").ligerGetComboBoxManager().selectValue(newCarTypString);
        $("#newCarTyp").ligerGetComboBoxManager().updateStyle();

        var usedCarTypString  = data.usedCarString;
        $("#usedCarTyp").ligerGetComboBoxManager().selectValue(usedCarTypString);
        $("#usedCarTyp").ligerGetComboBoxManager().updateStyle();

        var bizScope = data.bizScopeCdStr;
        $("#bizScope").ligerGetComboBoxManager().selectValue(bizScope);
        $("#bizScope").ligerGetComboBoxManager().updateStyle();
        //是否回购处理
        $("input[name='isBuyBack'][value=" + data.isBuyBack + "]").prev(".l-radio").click();
        //项目类型 处理
        var prjTypCdsString = data.prjTypCdsString;
        $("#prjTypCds").ligerGetComboBoxManager().selectValue(prjTypCdsString);
        $("#prjTypCds").ligerGetComboBoxManager().updateStyle();
        // jiangzg add 2017-7-31 16:52:27 专车
        if (data.splTypCd) {
            var cd = data.splTypCd;
            var _stc = $("#splTypCd").ligerGetCheckBoxManager();
            if (!_str && _str != null) {
                _stc.setValue(data.splTypCd);
                _stc.updateStyle();
            }
        }
        if (data.coopDt) {
            var date = new Date(data.coopDt);
            var dateStr = DateUtils.formatDate(date, DateUtils.YYYY_MM_DD);
            $("#coopDt").val(dateStr);
        }
        if (data.splTypCd != null && '1' == data.splTypCd) {
            $("#zk_01").css("display", 'block');
            $("#zk_02").css("display", 'block');
            $("#zk_03").css("display", 'block');
            $("#zk_04").css("display", 'block');
            $("#zk_05").css("display", 'block');
            $("#agtSec").val(data.agtSec);
            $("#agtThd").val(data.agtThd);
            $("#bscTaskQty").val(data.bscTaskQty);
            $("#entDepAmt").val(data.entDepAmt);
            $("#prdMaxValAmt").val(data.prdMaxValAmt);
            oldAgtSec = data.agtSec;
            oldAgtThd = data.agtThd;
            oldBscTaskQty = data.bscTaskQty;
            oldEntDepAmt = data.entDepAmt;
            oldPrdMaxValAmt = data.prdMaxValAmt;
        }
    };
    //动态字段值的设置
    //		2017-5-20 12:38:28 by jiangzg delete
    function setExtData(data) {
        var form = liger.get("formSet1");
        if (data) {
            form.setData({
//		    		bilWayCd:data.bilWayCd,
                prjLvlCd: data.prjLvlCd,
            });
        }
    };
    var comboGrid_defaultValue = "${mfrIdsString}"; //初始值(value)
    var comboGrid_defaultText = "${mfrNms}"; //初始值(text)
    var isInit_setSearchComboVal = false; //是否初始化的时候已经赋完初始值？
    //厂商带搜索
    var combo_Mng = $("#mfrIds").ligerComboBox({
        width: 400,
        selectBoxWidth: 380,
        selectBoxHeight: 240,
        valueField: 'id',
        textField: 'mfrName',
        isMultiSelect: true,
        grid: getGridOptions(true),
        condition: {
            labelWidth: 0,
            space: 5,
            fields: [{name: 'mfrName', width: 150, keyName: 'id'}]
        },
        delayLoadGrid: false,
        onChangeValue: function (value) {
            if (combo_Mng) {
                if (value == "") comboGrid_defaultValue = ""; //如果点击清空'x'，就滞空初始值
                $("#mfrIds").show_ligerComboItems();
            }
            SetIframe_height();
        }
    });


    function getGridOptions(checkbox) {
        var url;
        var _splId = $("#sId").val();
        if (!_splId) {
            url = '<%=path%>/product/mfrInfo/initList.do?flag=quote'
        } else {
            url = '<%=path%>/product/mfrInfo/initList.do?flag=quote&mfrIdsString=' + comboGrid_defaultValue
        }
        var options = {
            usePager: false,
            columns: [
                {display: '厂商', name: 'mfrName', minWidth: 300}
            ],
            switchPageSizeApplyComboBox: false,
            url: url,
            method: 'get',
            dataAction: 'local',
            pageSize: 10,
            root: 'rows',
            record: 'total',
            usePagerOnLessPagesize: false,
            cssClass: "SMALL_grid",
            checkbox: checkbox,
            frozen: false,
            isSelected: function (rowdata) {
                if (comboGrid_defaultValue == "") return false;
                var defaultItems = comboGrid_defaultValue.split(";");
                if (!isInit_setSearchComboVal) { //只在初始化时执行一次，在onAfterShowData后改变
                    for (var i = 0; i < defaultItems.length; i++) {
                        if (rowdata[combo_Mng.options.valueField] == defaultItems[i]) return true;
                    }
                }
                return false;
            },
            onAfterShowData: function (currentData) {
                if (!isInit_setSearchComboVal) { //只在初始化时执行一次，在onAfterShowData后改变
                    //combo_Mng.selectValue(comboGrid_defaultValue);
                    combo_Mng.setInputValue(comboGrid_defaultValue, comboGrid_defaultText, true);
                    isInit_setSearchComboVal = true;
                }
            }
        };
        return options;
    }

    //联系人新增
    function splRlAddBtnEvent() {
        npSocialRlGrid.addRow({
            rlNm: '',
            rlTypCd: '',
            tel: '',
            certTypCd: '0',
            certTypCdNm: '身份证',
            certNo: '',
            rlRem: ''
        });
    };

    function deleteDB(rowdata_id, _id) {
        //删除数据库
        var _ids = [];
        _ids.push(_id);
        $.ligerDialog.confirm(LogUtils.LOG_CMM_DELETE_CONFIRM, function (flag) {
            if (flag == false) return;
            var wait_dialog;
            $.ajax({
                type: 'post',
                dataType: 'json',
                data: {ids: JSON.stringify(_ids)},
                url: '<%=path%>/product/splRlPsn/removeByIds.do',
                beforeSend: function () {
                    wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
                },
                success: function (msg) {
                    wait_dialog.close();
                    if (msg.success == 1) {
                        $.ligerDialog.SQalert({content: msg.info, SQ_type: "success"});
                        npSocialRlGrid.reload();
                    } else {
                        $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                    }
                }
            });
        });
    }

    function deletePage(rowdata_id) {
        $.ligerDialog.confirm(LogUtils.LOG_CMM_DELETE_CONFIRM, function (flag) {
            if (flag == false) return;
            //删除页面
            npSocialRlGrid.deleteRow(rowdata_id);
        })
    }

    //证件类型
    var certTypCdListJSON = [];
    <c:if test="${not empty certTypCdListJSON}">
    certTypCdListJSON = ${certTypCdListJSON};
    </c:if>
    //默认必填项
    var mustAddRlPsnJSON = [];
    <c:if test="${not empty mustAddRlPsnTypCdJSON}">
    mustAddRlPsnJSON = ${mustAddRlPsnTypCdJSON};
    console.log("mustAddRlPsnJSON ==="+JSON.stringify(mustAddRlPsnJSON));
    </c:if>
    //默认非必填项
    var noAddRlPsnJSON = [];
    <c:if test="${not empty noAddRlPsnTypCdJSON}">
    noAddRlPsnJSON = ${noAddRlPsnTypCdJSON};
    console.log("noAddRlPsnJSON ==="+JSON.stringify(noAddRlPsnJSON));
    </c:if>
    //联系人类型
    var rlTypCDListJSON = [];
    <c:if test="${not empty rlTypCDListJSON}">
    rlTypCDListJSON = ${rlTypCDListJSON};
    </c:if>
    //初始化主要人员信息
    function initSplRlGrid() {
        var _sId = $("#sId").val();
        var _applyId = $("#applyId").val();
        var _audStsCd = ${isCheckVerify};
        //alert(_audStsCd)
        npSocialRlGrid = $("#ligergrid_A1").ligerGrid({

            url: '<%=path%>/product/splApplyInfo/initSplRlPsnList.do?',
            method: 'get',
            parms: {splId: _sId, applyId: _applyId},
            async: false,
            columns: [
                {
                    display: '联系人姓名(<span class="c_red">*</span>)', name: 'rlNm', width: 150, editor: {type: 'text'},
                    validate: function (value,rowData,col) {
                        //if (StringUtils.isEmpty(value) && CollectionUtils.isNotEmpty(mustAddRlPsnJSON) && mustAddRlPsnJSON.indexOf(rowData.rlTypCd) >= 0) return "此项为必填项！";
                        if (StringUtils.isEmpty(value)) return "此项为必填项！";
                    }
                },
                {
                    display: '联系人类型(<span class="c_red">*</span>)', name: 'rlTypCd', width: 140,
                    editor: {
                        type: 'select',
                        data: rlTypCDListJSON,
                        valueField: 'key',
                        textField: 'value'
                    },
                    valueField: 'rlTypCd',
                    textField: 'rlTypCdNm',
                    render: function (item) {
                        return item.rlTypCdNm;
                    },
                    validate: function (value,rowData) {
                        //if (StringUtils.isEmpty(value) && CollectionUtils.isNotEmpty(mustAddRlPsnJSON) && mustAddRlPsnJSON.indexOf(rowData.rlTypCd) >= 0) return "此项为必填项！";
                        if (StringUtils.isEmpty(value)) return "此项为必填项！";
                    }
                },
                {display: '股比',name:'stockRatio',width:100},
                {
                    display: '证件类型', name: 'certTypCd', width: 140,
                    editor: {
                        type: 'select',
                        data: certTypCdListJSON,
                        valueField: 'key',
                        textField: 'value'
                    },
                    valueField: 'certTypCd',
                    textField: 'certTypCdNm',
                    render: function (item) {
                        return item.certTypCdNm;
                    },
                    validate: function (value,rowData) {
                        //if (StringUtils.isEmpty(value) && CollectionUtils.isNotEmpty(mustAddRlPsnJSON) && mustAddRlPsnJSON.indexOf(rowData.rlTypCd) >= 0) return "此项为必填项！";
                        if (StringUtils.isEmpty(value)) return "此项为必填项！";
                    }
                },
                {
                    display: '关联公司', name: 'rlNm', minWidth: 60,
                    render: function (rowdata, rowindex, value) {
                    	if(_audStsCd == 1){
                        	return '<a href="javascript:toRlEntPage(\''+value+'\');" class="sq-button-hasicon"><i class="sqBtnIco_1"></i></a>';
                    	}else{
                    		return '';
                    	}
                    }
                },
                /* { display: '证件号', name: 'certNo', minWidth: 170,align:'left', render: function(rowdata, rowindex, value){
                    if (value != null && value != '') {
                    	if(_audStsCd == 1){
                        	return '<a href="javascript:toCertNoCheckPage(\''+value+'\');" class="sq-button-hasicon link">'
                            	+ '<i class="sqBtnIco_1"></i></a>'
                            	+ value;
                    	}else{
                    		return '';
                    	}
                    }
                }}, */
                {
                    display: '证件号', name: 'certNo', width: 150, editor: {type: 'text'},
                    render: function (value,rowData) {
                        if(StringUtils.isEmpty(value.certNo) && StringUtils.isNotEmpty(value.rlTypCd)){
                            if(noAddRlPsnJSON.indexOf(value.rlTypCd) >= 0){
                                return '<span class="c_gray">(非必填信息)</span>';
                            }else{
                                return '<span class="c_gray">(必填信息)</span>';
                            }
                        }
                        if(_audStsCd == 1){
                        	return '<a href="javascript:toCertNoCheckPage(\''+value.certNo+'\');" class="sq-button-hasicon link">'
                            	+ '<i class="sqBtnIco_1"></i></a>'
                            	+ value.certNo;
                    	}else{
                    		return value.certNo;
                    	}
                    },
                    validate: function (value,rowData) {
                        //if (StringUtils.isEmpty(value) && CollectionUtils.isNotEmpty(mustAddRlPsnJSON) && mustAddRlPsnJSON.indexOf(rowData.rlTypCd) >= 0) return "此项为必填项！";
                        if (StringUtils.isEmpty(value)){
                            if((CollectionUtils.isEmpty(noAddRlPsnJSON)) || (CollectionUtils.isNotEmpty(noAddRlPsnJSON) && noAddRlPsnJSON.indexOf(rowData.rlTypCd) < 0)){
                                return "此项为必填项！";
                            }
                        }
                    }

                },
                {
                    display: '联系电话', name: 'tel', width: 150, editor: {type: 'text'},
                    render: function (value,rowData) {
                        if(StringUtils.isEmpty(value.tel) && StringUtils.isNotEmpty(value.rlTypCd)){
                            if(noAddRlPsnJSON.indexOf(value.rlTypCd) >= 0){
                                return '<span class="c_gray">(非必填信息)</span>';
                            }else{
                                return '<span class="c_gray">(必填信息)</span>';
                            }
                        }
                        return value.tel;
                    },
                    validate: function (value,rowData) {
                        //if (StringUtils.isEmpty(value) && CollectionUtils.isNotEmpty(mustAddRlPsnJSON) && mustAddRlPsnJSON.indexOf(rowData.rlTypCd) >= 0) return "此项为必填项！";
                        if (StringUtils.isEmpty(value)){
                            if((CollectionUtils.isEmpty(noAddRlPsnJSON)) || (CollectionUtils.isNotEmpty(noAddRlPsnJSON) && noAddRlPsnJSON.indexOf(rowData.rlTypCd) < 0)){
                                return "此项为必填项！";
                            }
                        }
                    }
                },
                {display: '备注', name: 'rlRem', minWidth: 150, editor: {type: 'text'}},
                {
                    display: '操作', minWidth: 80, align: 'left',
                    render: function (rowdata, rowindex, value) {
                        var d = "";
                        if (rowdata.isDefault != 1 && audStsCd != 1 && rowdata.rlTypCd != 1) {
                            if (rowdata.id) {
                                d = '<a class="sq-button-hasicon" href="javascript:deleteDB(';
                                d += "'" + rowdata.__id + "'";
                                d += ",'" + rowdata.id + "'";
                                d += ')"><i class="sqBtnIco_7"></i>删除</a>';
                            } else {
                                d = '<a class="sq-button-hasicon" href="javascript:deletePage(';
                                d += "'" + rowdata.__id + "'";
                                d += ')"><i class="sqBtnIco_7"></i>删除</a>';
                            }
                        }
                        return d;
                    }
                },
                { display: '工商信息校验', name: 'checkVerify', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        var h = "";
                        if(_audStsCd == 1){
                            if(rowdata.busInfoVerify == 2 || rowdata.busInfoVerify == null && rowdata.id != null){
                                //h += "<a  href = "javascript:checkRlPsn('Verify',\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\');" class = "sq-button sq-button-round">验证</a>"

                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(1,\''+rowdata.id+'\','+rowdata.applyPsnId+',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h +='<div class="sq-button sq-button-round disabled">已校验</div>'
                            }
                            /* if(rowdata.busInfoVerify != 1){
                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(1,\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h +='<div class="sq-button sq-button-round disabled">已校验</div>'
                            } */
                        }
                        return h;
                    }
                },
                { display: '工商信息校验结果', name: 'busInfoVerify', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        if(rowdata.busInfoVerify == 1){
                            return "一致" ;
                        }else if(rowdata.busInfoVerify == -1){
                            return "不一致";
                        }else if(rowdata.busInfoVerify == 0){
                            return "未查得";
                        }else{
                            return "";
                        }
                    }
                },
                { display: '三要素校验（机构1）', name: 'PYCheck', minWidth: 150,
                    render: function(rowdata, rowindex, value){

                        var h = "";
                        if(_audStsCd == 1){
                            if(rowdata.pyPerVerify == 2 || rowdata.pyPerVerify == null && rowdata.id != null){
                                //h += "<a  href = "javascript:checkRlPsn('Verify',\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\');" class = "sq-button sq-button-round">验证</a>"

                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(2,\''+rowdata.id+'\','+rowdata.applyPsnId+',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h+='<div class="sq-button sq-button-round disabled">已校验</div>'
                            }
                            /* if(rowdata.pyPerVerify != 1){
                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(2,\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h+='<div class="sq-button sq-button-round disabled">已校验</div>'
                            } */
                        }
                        return h;
                    }
                },
                { display: '三要素校验结果1', name: 'pyPerVerify', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        if(rowdata.pyPerVerify == 1){
                            return "一致" ;
                        }else if(rowdata.pyPerVerify == -1){
                            return "不一致";
                        }else if(rowdata.pyPerVerify == 0){
                            return "未查得";
                        }else{
                            return "";
                        }
                    }
                },
                { display: '三要素校验（机构2）', name: 'TDCheck', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        var h = "";
                        if(_audStsCd == 1){
                            if(rowdata.tdPerVerify == 2 ||  rowdata.tdPerVerify == null && rowdata.id != null){
                                //h += "<a  href = "javascript:checkRlPsn('Verify',\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\');" class = "sq-button sq-button-round">验证</a>"

                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(3,\''+rowdata.id+'\','+rowdata.applyPsnId+',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h +='<div class="sq-button sq-button-round disabled">已校验</div>'
                            }
                            /* if(rowdata.tdPerVerify != 1){
                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(3,\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h +='<div class="sq-button sq-button-round disabled">已校验</div>'
                            } */
                        }
                        return h;
                    }
                },
                { display: '三要素校验结果2', name: 'tdPerVerify', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        if(rowdata.tdPerVerify == 1){
                            return "一致" ;
                        }else if(rowdata.tdPerVerify == -1){
                            return "不一致";
                        }else if(rowdata.tdPerVerify == 0){
                            return "未查得";
                        }else{
                            return "";
                        }
                    }
                },
                { display: '三要素校验（机构3）', name: 'BRCheck', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        var h = "";
                        if(_audStsCd == 1){
                            if(rowdata.brPerVerify == 2 || rowdata.brPerVerify == null  && rowdata.id != null){
                                //h += "<a  href = "javascript:checkRlPsn('Verify',\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\');" class = "sq-button sq-button-round">验证</a>"
                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(4,\''+rowdata.id+'\','+rowdata.applyPsnId+',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h +='<input class="sq-button sq-button-round disabled" type="button" value="已校验" disabled>'
                            }
                            /* if(rowdata.brPerVerify != 1){
                                h+= '<a class="sq-button sq-button-round" href="javascript:checkRlPsn(4,\''+rowdata.id+'\',\''+rowdata.rlNm+'\',\''+rowdata.certNo+'\',\''+rowdata.tel+'\',\''+rowdata.rlTypCd+'\');">验证</a>'
                            }else{
                                h +='<input class="sq-button sq-button-round disabled" type="button" value="已校验" disabled>'
                            } */

                        }
                        return h;
                    }
                },
                { display: '三要素校验结果3', name: 'brPerVerify', minWidth: 150,
                    render: function(rowdata, rowindex, value){
                        if(rowdata.brPerVerify == 1){
                            return "一致" ;
                        }else if(rowdata.brPerVerify == -1){
                            return "不一致";
                        }else if(rowdata.brPerVerify == 0){
                            return "未查得";
                        }else{
                            return "";
                        }
                    }
                },
            ],
            onBeforeEdit: function (e) {
                if (audStsCd == 1) {
                    e.column.editor.readonly = true;
                } else if (auditStatus == 1 && audStsCd != 0) {
                    var strIsDefault = e.record.isDefault;
                    if (StringUtils.isNotEmpty(strIsDefault) && strIsDefault == 1) {
                        e.column.editor.readonly = true;
                    } else {
                        e.column.editor.readonly = false;
                    }
                } else {
                    var strIsDefault = e.record.isDefault;
                    var colName = e.column.columnname;
                    //if (StringUtils.isNotEmpty(strIsDefault) && strIsDefault == 1) {
                        if (colName == 'rlTypCd' && e.record.rlTypCdNm != null) {
                            e.column.editor.readonly = true;
                        } else {
                            e.column.editor.readonly = false;
                        }
                    //} else {
                    	
                     //   e.column.editor.readonly = false;
                    //}
                    
                }
            },
            usePager: false,
            root: 'rows',
            record: 'total',
            hideLoadButton: true,
            width: '100%',
            height: 300,
            heightDiff: -2,
            enabledEdit: true,
            isScroll: false,
            checkbox: false,
            rownumbers: true,
            allowUnSelectRow: true,
            alternatingRow: false,
            enabledSort: false,
            onAfterShowData: function () {
                SetIframe_height();
            }
        });
    };

    //初始化Tab页
    function initTab() {
        pageInTab = $("#pageInTab").ligerTab({
            height: 'auto',
            contextmenu: false,
            minIframeHeight: GET_minIframeHeight(),
            onBeforeSelectTabItem: function (tabid) {
                var _sId = $("#sId").val();
                if (tabid != "tabA") {
                    if (!_sId) {
                        top.$.ligerDialog.SQalert({content: "请确认供应商基本信息已存在", SQ_type: "warning"});
                        return false;
                    }
                }
            },
            onAfterSelectTabItem: function (tabid) {
                if (loadedTabs.indexOf(tabid) < 0) {
                    var _sId = $("#sId").val();
                    if (tabid != "tabA") {
                        if (!_sId) {
                            top.$.ligerDialog.SQalert({content: "请确认供应商基本信息已存在", SQ_type: "warning"});
                            return false;
                        }
                    }
                    loadedTabs.push(tabid);
                    if (audStsCd == 1) {
                        switch (tabid){
                            case "tabB":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splInfo/toSplFileAddPage.do?isDetail=1&splId=" + _sId +"&splAttrCd="+splAttrCd +"&qualTypCd="+qualTypCd+"&isApply="+_isApply+"&isCheckVerify="+isCheckVerify);
                                break;
                            case "tabC":
                                pageInTab.setTabItemSrc(tabid, "");
                                break;
                            case "tabD":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splBank/toListPageDetail.do?splId=" + _sId+"&audStsCd="+audStsCd );
                                break;
                            case "tabE":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splInfo/toSplPrjBscInfoDetailList.do?splId=" + _sId+"&audStsCd="+audStsCd );
                                break;
                            case "tabG":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splUsrR/toSplConfigDtail.do?splId=" + _sId+"&audStsCd="+audStsCd );
                                break;
                            case "tabH":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splApplyInfo/toSplInfoApplyListPage.do?splId=" + _sId+"&audStsCd="+audStsCd );
                                break;
                            case "tabJ":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/customer/cstManualRelation/toListPage.do?Id=" + _sId +"&useType=2&splAttrCd=" + splAttrCd);
                                break;
                        }
                    }else if (audStsCd == 0){
                    	switch (tabid){
                        case "tabB":
                            pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splInfo/toSplFileAddPage.do?isDetail=1&splId=" + _sId +"&splAttrCd="+splAttrCd +"&qualTypCd="+qualTypCd+"&isApply="+_isApply+"&isCheckVerify="+isCheckVerify);
                            break;
                        case "tabC":
                            pageInTab.setTabItemSrc(tabid, "");
                            break;
                        case "tabD":
                            pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splBank/toListPageDetail.do?splId=" + _sId+"&audStsCd="+audStsCd );
                            break;
                        case "tabE":
                            pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splInfo/toSplPrjBscInfoDetailList.do?splId=" + _sId+"&audStsCd="+audStsCd );
                            break;
                        case "tabG":
                            pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splUsrR/toSplConfigDtail.do?splId=" + _sId+"&audStsCd="+audStsCd );
                            break;
                        case "tabH":
                            pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splApplyInfo/toSplInfoApplyListPage.do?splId=" + _sId+"&audStsCd="+audStsCd );
                            break;
                        case "tabJ":
                            pageInTab.setTabItemSrc(tabid, "<%=path%>/customer/cstManualRelation/toListPage.do?Id=" + _sId +"&useType=2&splAttrCd=" + splAttrCd);
                            break;
                    }
                    }else{
                        switch (tabid) {
                            case "tabB":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splInfo/toSplFileAddPage.do?splId=" + _sId +"&splAttrCd="+splAttrCd +"&qualTypCd="+qualTypCd+"&isApply="+_isApply+"&isCheckVerify="+isCheckVerify);
                                break;
                            case "tabC":
                                pageInTab.setTabItemSrc(tabid, "");
                                break;
                            case "tabD":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splBank/toListPage.do?allowMdfBank=${allowMdfBank}&proIntId=${proIntId}&splId=" + _sId+"&audStsCd="+audStsCd);
                                break;
                            case "tabE":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splInfo/toSplPrjBscInfoDetailList.do?splId=" + _sId+"&audStsCd="+audStsCd);
                                break;
                            case "tabG":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splUsrR/toSplConfigPage.do?splId=" + _sId+"&audStsCd="+audStsCd);
                                break;
                            case "tabH":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/product/splApplyInfo/toSplInfoApplyListPage.do?splId=" + _sId+"&audStsCd="+audStsCd);
                                break;
                            case "tabJ":
                                pageInTab.setTabItemSrc(tabid, "<%=path%>/customer/cstManualRelation/toListPage.do?Id=" + _sId +"&useType=2&cstType=" + splAttrCd);
                                break;
                        }
                    }
                }
                ;
                SetIframe_height();
            }
        });
    };
 	// 跳转到证件号查重页面
    function toCertNoCheckPage(certNo){
        Add_navTab('tab_cert_no_check','证件号查重页面','<%=path%>/spl/cstRelInfoView/toCstRelInfoView.do?certNo=' + certNo);
    }
    // 跳转到关联公司页面
    function toRlEntPage(_name){
    	var params = '';
    	params += 'name=' + _name;
    	params += '&entname=' + $('#splNm').text();
        Add_navTab('tab_rl_ent_page'+_name,'关联公司','<%=path%>/splExecRypossha/toListPage.do?' + params);
    }
    function checkRlPsn(type,dataId,applyPsnId,rlNm,certNo,tel,rlTypCd){
        var _type ;
        if(type == 1){
            _type = 'verify' ;
        }
        if(type == 2){
            _type = 'PY' ;
        }
        if(type == 3){
            _type = 'TD' ;
        }
        if(type == 4){
            _type = 'BR' ;
        }
        var splId = $("#sId").val();
        var _url = '<%=path%>/product/splRlPsn/checkRlPsn.do';
        $.ajax({
            type: 'post',
            dataType : 'json',
            data:{
                type:_type,
                dataId:dataId,
                rlNm:rlNm,
                certNo:certNo,
                tel:tel,
                splId:splId,
                applyPsnId:applyPsnId
            },
            url:_url,
            success:function(msg){
                if(msg.success == 1){
                    //alert(msg.info)
                    initSplRlGrid();

                }else{
                    // $.ligerDialog.SQalert({content:msg.data, SQ_type: "error"});
                    initSplRlGrid();
                }
            }
        });
    }

    //修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13

    /*
    function initFlowData() {
        var dataId = $("#sId").val();
        var applyId = $("#applyId").val();
        var currBuOrgCdStr=$("currBuOrgCd").val();
        if (!dataId) {
            return;
        }
        var _url = '<%=path%>/product/splApplyInfo/initBizFlowRl.do';
        $.ajax({
            type: 'get',
            dataType: 'json',
            data: {
                dataId: dataId,
                flowTabNm: 'SPL_BSC_INFO',
                codeGrpCd: 'FLW0001',
                applyId: applyId
            },
            url: _url,
            success: function (msg) {
                if (msg.success == 1) {
                    console.log(JSON.stringify(msg.data));
                    setBizFlowData(msg.data);//设置数据
                } else {
                    $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                }
            }
        });
    }

    function setBizFlowData(data) {
        if (data) {
            for (var i = 0; i < data.length; i++) {
                var sysBizFlowRlVO = data[i];
                $("#" + sysBizFlowRlVO.pdefKey + "").ligerGetCheckBoxManager().setValue(true);
                $("#flowNum" + sysBizFlowRlVO.pdefKey + "").val(sysBizFlowRlVO.flowNum);
                if(sysBizFlowRlVO.pdefKey == "FLOW_00000001_035_001"){
                    if(sysBizFlowRlVO.flowNum == "-1"){
                        $("#flowNumcheckb").ligerGetCheckBoxManager().setValue(true);
                        $("#flowNumFLOW_00000001_035_001").val("");
                        $("#flowNumFLOW_00000001_035_001").attr("disabled","disabled");
                    }
                }
                if(sysBizFlowRlVO.pdefKey == "FLOW_00000001_007_001" && StringUtils.isNotEmpty(sysBizFlowRlVO.expireUncardNum)){
                    $("#expire" + sysBizFlowRlVO.pdefKey).val(sysBizFlowRlVO.expireUncardNum);
                } else {
                    $("#expireFLOW_00000001_007_001").val(2);
                }
            }
            if(data.length == 0){
                $("#expireFLOW_00000001_007_001").val(2);
            }
        }
        pDefKeyChange();
    }

    function pDefKeyChange() {
        var f = true;
        $("input[name='pDefKey']").each(function () {
            if (!$(this)[0].checked) {
                f = false;//有任意一个未选中 f则被赋值为false
            }
            if ($(this)[0].id == "FLOW_00000001_007_001") {
                if ($("#FLOW_00000001_007_001")[0].checked) {
                    $("#f_FLOW_00000001_007_001").show();
                } else {
                    $("#f_FLOW_00000001_007_001").hide();
                }
            }
            if ($(this)[0].id == "FLOW_00000001_035_001") {
                if ($("#FLOW_00000001_035_001")[0].checked) {
                    $("#f_FLOW_00000001_035_001").show();
                } else {
                    $("#f_FLOW_00000001_035_001").hide();
                }
            }
        });
        if (f) {
            $("#ALL").ligerGetCheckBoxManager().setValue(true);
        } else {
            $("#ALL").ligerGetCheckBoxManager().setValue(false);
        }

    }

    function allChange() {
        if ($("#ALL")[0].checked) {
            $("input[name='pDefKey']").each(function () {
                $(this).ligerGetCheckBoxManager().setValue(true);
            });
        } else {
            $("input[name='pDefKey']").each(function () {
                $(this).ligerGetCheckBoxManager().setValue(false);
            });
        }
        pDefKeyChange();
    }*/
    function wsCheck() {
        var _form = liger.get("formSet1");
        var _data = _form.getData();
        if($('#splAttrCd').val() != CustomerConstant.CST_TYPE_NP_CD){
            _data["npSocialRlGridJSON"] = JSON.stringify(npSocialRlGrid.getData());
        }
        if ($('#splAttrCd').val() == CustomerConstant.CST_TYPE_NP_CD) {
            _data["npSocialRlGridJSON"] = JSON.stringify(npSocialRlList);
        }
        var _url = '<%=path%>/npspl/splnpbscinfo/kingDeeWsCheck.do';

        $.ajax({
            type: 'post',
            url: _url,
            data: _data,
            dataType: "json",
            success: function (msg) {
                if ( 0 == msg.success) {
                    $.ligerDialog.SQalert({content:msg.info, SQ_type: "error"});
                    return false;
                }else if(1 == msg.success){
                    inputReason();
                }
            }
        });
    }
    function inputReason(){
        var form = liger.get("formSet1");
        if (!form.valid()) {
            $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_MUST_FIX_ITEM_INFO, SQ_type: "warning"});
            return false; //验证不通过，不执行以下代码
        }

        //jiangzg 2018-8-21 09:03:25 modify
        //修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13
        /*if(currBuOrgCd=='00000001' ||  currBuOrgCd=='0000' || audStsCd == 1){
            if ($("#FLOW_00000001_007_001")[0].checked) {
                var flowNum = $("#flowNumFLOW_00000001_007_001").val();
                var expireNum = $("#expireFLOW_00000001_007_001").val();
                console.log("flowNum --" + flowNum);
                if(!flowNum){
                    $.ligerDialog.SQalert({content: "提前放款，流程权限支持不上牌资产数据未维护！", SQ_type: "warning"});
                    return false; //验证不通过，不执行以下代码
                }
                if(!expireNum){
                    $.ligerDialog.SQalert({content: "提前放款，流程权限超期30天未上牌车辆数据未维护！", SQ_type: "warning"});
                    return false; //验证不通过，不执行以下代码
                }
            }
            if ($("#FLOW_00000001_035_001")[0].checked) {
                var flowNum = $("#flowNumFLOW_00000001_035_001").val();
                console.log("flowNum --" + flowNum);
                var isOrCheckLimit = $("#flowNumcheckb")[0].checked;
                console.log("isOrCheckLimit ===" + isOrCheckLimit );
                if(!flowNum && !isOrCheckLimit){
                    $.ligerDialog.SQalert({content: "准时放款，流程权限支持不上牌资产数据未维护！", SQ_type: "warning"});
                    return false; //验证不通过，不执行以下代码
                }
            }
        }*/
        var isValid = SQ.validGrid('ligergrid_A1');
        if (isValid == false) {
            $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_MUST_FIX_ITEM_INFO, SQ_type: "warning"});
            return false;
        }
        var data = form.getData();
        var id = $("#sId").val();
        var applyId = $("#applyId").val();
        data["id"] = id;
        data["applyId"] = applyId;
        data["flowTabNm"] = 'SPL_BSC_INFO';
        data["codeGrpCd"] = 'FLW0001';
        //增加判断供应商属性，决定有无主要联系人  zhaoyong
        if ($('#splAttrCd').val() != CustomerConstant.CST_TYPE_NP_CD) {
            data["npSocialRlGridJSON"] = JSON.stringify(npSocialRlGrid.getData());
        }

        var fileParams = upload_result_params;//getUploadResultParams(); //获取附件上传的信息
        console.log("fileParams ==" + JSON.stringify(fileParams));
        data["fileParams"] = JSON.stringify(fileParams);

        checkChangelowSplInfo(data);

        //$.ligerDialog.SQopen({
        //	width: 400,
        //    height:230,
        //    title : '操作原因',
        //    target : $('#reasonFromSet'),
        //url:'<%=path%>/spl/splOpLogRec/toAddBlackListReasonPage.do?splId='+_id,
        //    buttons: [{
        //        	text: "确定", type: 'ok', cls: 'l-dialog-btn-ok',
        //            onclick: function (item, Dialog) {
        //            		var form = new liger.get("reasonFromSet");
        //            		if (!form.valid()) {
        //            	    	top.$.ligerDialog.SQalert({content: LogUtils.LOG_CMM_MUST_FIX_ITEM_INFO , SQ_type: "warning" });
        //            	        return false; //验证不通过，不执行以下代码
        //            	    }
        //            		checkChangelowSplInfo(data);
        //            		Dialog.hide();
        //            		$('#reason').val('');
        //            }
        //        }, {
        //            text: "取消", type: 'cancel', cls: 'l-dialog-btn-no',
        //            onclick: function (item, Dialog) {
        //            	Dialog.hide();
        //            	$('#reason').val('');
        //            }
        //        }
        //	]
        //});
    }

    function relationshipsView(){
        var org_cd = $("#succ").val();
        var id = $("#sid").val();
        var currentUserId = '${currentUserId}'
        if(!org_cd){
            $.ligerDialog.SQalert({content: "社会同一信用代码为空！", SQ_type: "warning"});
            return false ;
        }
        Add_navTab('tab_relationships_view_data'+id+'1','集团关联图谱','<%=path%>/knowledgeGraph/init/initGraphGroupPage.do?org_code='+org_cd+'&usrId='+currentUserId);
    }
    function checkChangelowSplInfo(data) {
        var url = '<%=path%>/product/splApplyInfo/checkChangeSplInfo.do';
        $.ajax({
            type: 'post',
            dataType: 'json',
            data: data,
            url: url,
            beforeSend: function () {
                wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
            },
            success: function (msg) {
                wait_dialog.close();
                if (msg.success == 1) {
                    if (msg.info == 1) {
                        startSqlAdmissionFlow();
                    } else {
                        saveSplInfo('');
                    }
                } else {
                    $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                }
            }
        });
    }

    //发起审核流程
    function startSqlAdmissionFlow() {
        var modelTyp = FlowConstant.FLOW_MODEL_TYP_SPL_CHG;//流程业务分类-供应商准入
        if (StringUtils.isEmpty(modelTyp)) {
            return;
        }
        var flowDialog = $.ligerDialog.SQopen({
            url: '<%=path%>/flow/flow/toForStartListPage.do?modelTyp=' + modelTyp,
            width: 700,
            height: 400,
            title: '请选择要发起的流程',
            buttons: [{
                text: "确定", type: 'ok', cls: 'l-dialog-btn-ok',
                onclick: function (item, Dialog) {
                    if (Dialog.onOk) {
                        $.ligerDialog.SQconfirm('是否确定发起变更流程?', function (flag) {
                            if (flag == false) {
                                return;
                            } else {
                                Dialog.onOk();
                            }
                        })
                    }
                }
            }, {
                text: "取消", type: 'cancel', cls: 'l-dialog-btn-no',
                onclick: function (item, Dialog) {
                    if (Dialog.onCancel) Dialog.onCancel();
                }
            }
            ],
            onClose: function () {
                var json = flowDialog._DATA;
                if (!json) {
                    return;
                }
                saveSplInfo(json);
            }
        });
    }

    function saveSplInfo(json) {
        var form = liger.get("formSet1");
        var reason = $('#reason').val();
        if (!form.valid()) {
            $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_MUST_FIX_ITEM_INFO, SQ_type: "warning"});
            return false; //验证不通过，不执行以下代码
        }

        var isValid = SQ.validGrid('ligergrid_A1');
        if (isValid == false) {
            $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_MUST_FIX_ITEM_INFO, SQ_type: "warning"});
            return false;
        }
        var data = form.getData();
        data.isBuyBack = $('input[name="isBuyBack"]:checked ').val();
        /* zhaoyong  */
        data.isAuthCrdChk = $('input[name="isAuthCrdChk"]:checked ').val();

        data["regDt"] = $("#regDt").val();
        data["expDt"] = $("#expDt").val();
        data["rgnPrCd"] = getRgnProvCd();//获取省代码
        data["rgnCyCd"] = getRgnCityCd();//获取市代码

        data["splAttrCd"] = $("#splAttrCd").val();
        var id = $("#sId").val();
        var applyId = $("#applyId").val();
        data["id"] = id;
        data["applyId"] = applyId;
        data["flowTabNm"] = 'SPL_BSC_INFO';
        data["codeGrpCd"] = 'FLW0001';
        if (StringUtils.isNotEmpty(json)) {
            data["procDefKey"] = json.procDefKey;
            data["procDefId"] = json.procDefId;
            data["procNo"] = json.procNo;
        }
        //增加判断供应商属性，决定有无主要联系人  zhaoyong
        if ($('#splAttrCd').val() != CustomerConstant.CST_TYPE_NP_CD) {
            data["npSocialRlGridJSON"] = JSON.stringify(npSocialRlGrid.getData());
        }

        //var fileParams = getUploadResultParams(); //获取附件上传的信息
        var fileParams = upload_result_params; //获取附件上传的信息
        data["fileParams"] = JSON.stringify(fileParams);

        console.log("saveSplInfo fileParams[] == "+ JSON.stringify(fileParams));

        data["reason"] = reason;
        //修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13
        /*if(currBuOrgCd=='00000001' ||  currBuOrgCd=='0000' || audStsCd == 1){
            var isOrCheckLimit = $("#flowNumcheckb")[0].checked;

            console.log("isOrCheckLimit ===" + isOrCheckLimit );
            if(isOrCheckLimit){
                data["isOrCheckLimit"] = '-1' ;
                console.log("data[isOrCheckLimit] ===" + data["isOrCheckLimit"] );
            }
        }*/
        var url = '<%=path%>/product/splApplyInfo/mdfInfoStartApplyFlow.do';
        oldAgtSec = "";
        oldAgtThd = "";
        oldBscTaskQty = "";
        oldEntDepAmt = "";
        oldPrdMaxValAmt = "";
        var wait_dialog;
        $.ajax({
            type: 'post',
            dataType: 'json',
            data: data,
            url: url,
            beforeSend: function () {
                wait_dialog = $.ligerDialog.SQalert({content: LogUtils.LOG_CMM_DATA_LOADING, SQ_type: "waitting"});
            },
            success: function (msg) {
                if (msg.success == 1) {
                    if (StringUtils.isNotEmpty(json)) {
                        parent.$.ligerDialog.SQalert({content: msg.info, SQ_type: "success"});
                        Remove_navTab();
                        /*var url = '<%=path%>/flow/flow/getFlowNextAssigne.do?key=' + msg.info;
                        FlowUtils.alertNextFlowAssign1(url,function () {
                            Remove_navTab();
                        });*/
                    } else {
                        if (msg.data) {
                            $("#sId").val(msg.data);
                            npSocialRlGrid.setParm("splId", msg.data);
                            npSocialRlGrid.reload();
                        } else {
                            npSocialRlGrid.setParm("splId", $("#sId").val());
                            npSocialRlGrid.reload();
                        }
                        //回调刷新列表
                        var callback = GET_W2Wcallback();
                        callback();
                        $.ligerDialog.SQalert({content: msg.info, SQ_type: "success"});
                    }
                } else {
                    $.ligerDialog.SQalert({content: msg.info, SQ_type: "error"});
                }
                wait_dialog.close();
            }

        });
    }

    function disableFiled() {
        //供应商存在发起流程，主要信息不可编辑
        //0可以编辑 1不可以编辑 2 主要信息不可编辑
        if (auditStatus == 1 && audStsCd == 2) {
            if (liger.get("splNm")) {
                liger.get("splNm").setDisabled(true);
            }
            if (liger.get("bizLicNo")) {
                liger.get("bizLicNo").setDisabled(true);
            }
            if (liger.get("taxRegNo")) {
                liger.get("taxRegNo").setDisabled(true);
            }
            if (liger.get("orgCode")) {
                liger.get("orgCode").setDisabled(true);
            }

            //修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13
            /*if (liger.get("FLOW_00000001_007_001")) {
                liger.get("FLOW_00000001_007_001").setDisabled(true);
                liger.get("ALL").setDisabled(true);
            }
            var flowText=document.getElementById("flowNumFLOW_00000001_007_001");
            if (flowText) {
                flowText.disabled=true;
            }
            var expireText = document.getElementById("expireFLOW_00000001_007_001");
            if (expireText) {
                expireText.disabled=true;
            }*/
        }
        if (audStsCd == 1) {
            if (liger.get("splNm")) {
                liger.get("splNm").setDisabled(true);
            }
            if (liger.get("succ")) {
                liger.get("succ").setDisabled(true);
            }
            if (liger.get("bizLicNo")) {
                liger.get("bizLicNo").setDisabled(true);
            }
            if (liger.get("taxRegNo")) {
                liger.get("taxRegNo").setDisabled(true);
            }
            if (liger.get("orgCode")) {
                liger.get("orgCode").setDisabled(true);
            }
            //非汽车金融  供应商类型禁止
            if (currBuOrgCd != '00000005') {
                if (liger.get("prjLvlCd")) {
                    liger.get("prjLvlCd").setDisabled(true);
                }
            }
            //非重卡  供应商级别禁止
            if (currBuOrgCd != '00000001') {
                if (liger.get("splLvlCd")) {
                    liger.get("splLvlCd").setDisabled(true);
                }
            }
            if (liger.get("splTel")) {
                liger.get("splTel").setDisabled(true);
            }
            if (liger.get("splFax")) {
                liger.get("splFax").setDisabled(true);
            }
            if (liger.get("corpTypCd")) {
                liger.get("corpTypCd").setDisabled(true);
            }
            if (liger.get("regDt")) {
                liger.get("regDt").setDisabled(true);
            }
            if (liger.get("expDt")) {
                liger.get("expDt").setDisabled(true);
            }
            if (liger.get("regCapAmt")) {
                liger.get("regCapAmt").setDisabled(true);
            }
            if (liger.get("regCapUntCd")) {
                liger.get("regCapUntCd").setDisabled(true);
            }
            if (liger.get("paidCapAmt")) {
                liger.get("paidCapAmt").setDisabled(true);
            }
            if (liger.get("paidCapUntCd")) {
                liger.get("paidCapUntCd").setDisabled(true);
            }
            if(liger.get("ownerCd")){
                liger.get("ownerCd").setDisabled(true);
            }
            if (liger.get("regAddr")) {
                liger.get("regAddr").setDisabled(true);
            }
            //禁用省市
            disabledRgnProvCd();
            disabledRgnCityCd();
            if (liger.get("websit")) {
                liger.get("websit").setDisabled(true);
            }
            if (liger.get("bizScope")) {
                liger.get("bizScope").setDisabled(true);
            }
            if (liger.get("fileNo")) {
                liger.get("fileNo").setDisabled(true);
            }
            if (liger.get("postAddr")) {
                liger.get("postAddr").setDisabled(true);
            }
            if (liger.get("zipNo")) {
                liger.get("zipNo").setDisabled(true);
            }
            if (liger.get("prjTypCds")) {
                liger.get("prjTypCds").setReadonly(true);
            }
            if (liger.get("tkBrCd")) {
                liger.get("tkBrCd").setReadonly(true);
            }
            if (liger.get("carBrCd")) {
                liger.get("carBrCd").setReadonly(true);
            }
            if (liger.get("busBrCd")) {
                liger.get("busBrCd").setReadonly(true);
            }
            if(liger.get("newCarTyp")){
                liger.get("newCarTyp").setDisabled(true);
            }
            if(liger.get("usedCarTyp")){
                liger.get("usedCarTyp").setDisabled(true);
            }
            $("#othInfoCd").setDisabled_ligerTextarea(true);
            if (liger.get("mfrIds")) {
                liger.get("mfrIds").setReadonly(true);
            }
            if (liger.get("rebPct")) {
                liger.get("rebPct").setDisabled(true);
            }
            /*  liger.get("limChkTms").setDisabled(true); */
            $("#flowRem").setDisabled_ligerTextarea(true);
            if (liger.get("splLvlCd")) {
                liger.get("splLvlCd").setDisabled(true);
            }
        }
    }

    //修改供应商变更页面流程权限变更  fengzuoxiang  2019-06-13
    /*function fonselblur() {
        var val = $("#flowNumFLOW_00000001_035_001").val();
        if(val != "" && val != null){
            $("#flowNumcheckb").prop("disabled", true);
        }else{
            $("#flowNumcheckb").prop("disabled", false);
        }
    }

    function onsetNumVal() {
        //alert($('input[name=flowNumcheckb]:checked', '#flowNumcheckb'));
        //alert();
        console.log($('input[name=flowNumcheckb]:checked', '#flowNumcheckb'))
        //i++;
        var flag = false;
        if(currBuOrgCd == '00000001' ||currBuOrgCd == '0000'){
            flag = $("#flowNumcheckb")[0].checked;

            console.log("flag --"+flag);
            $("#flowNumFLOW_00000001_035_001").removeAttr("disabled");
            if(flag){
                $("#flowNumFLOW_00000001_035_001").attr("disabled","disabled");
                $("#flowNumFLOW_00000001_035_001").val("");
                flag = false;
            }else{
                $("#flowNumFLOW_00000001_035_001").removeAttr("disabled");
                flag = true;
            }
        }
    }*/

    function uploadFileByUrl(_url,_name){
        if(serverPrefixPath.length >1 && serverPrefixPath.indexOf("\"")>=0){
            serverPrefixPath = serverPrefixPath.substring(1,serverPrefixPath.length-1);
        }
        if(SQ.regs.img.test(_name)){
            //SQ.imgPreview(_url);
            //SQ.imgPreview(_url, true);
            if(_url.startsWith(serverPrefixPath)) {
                window.__ImgSrc = _url;
            } else {
                window.__ImgSrc = serverPrefixPath + _url;
            }
            window.__ImgTit = _name;
            window.open('<%=path%>/project/prjbscinfo/imgWinOpen.do', '', 'location=yes, width=800, height=600');
        }else{

            if(_url.startsWith(serverPrefixPath)) {
                window.open(_url);
            } else {
                window.open(serverPrefixPath + _url);
            }
        }
    }
</script>


</body>
</html>